문제

I've encountered the raw_native_types in a tlb import statement and I'm unclear of what the benefit of this attribute is. I've read the MSDN description for this (http://msdn.microsoft.com/en-us/library/8etzzkb6%28v=vs.71%29.aspx#_predir_raw_native_types) but it hasn't helped clearing it up for me. Can someone help explain it to me?

Thanks.

도움이 되었습니까?

해결책

The intention defines the benefit. If one really doesn't want to use _bstr_t or _variant_t because, who knows, one abominates them (not that uncommon), or one doesn't trust the compiler to actually do a good job at keeping them alive, or one already uses other smart wrappers, or one really likes to explicitly call SysFreeString and VariantClear, then one specifies raw_native_types.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top