C++#include和#import的区别

2022-01-25 00:00:00 gcc import visual-c++ include c++

#include#import在C++中有什么区别?

What is the difference between #include and #import in C++?

推荐答案

#import 是微软特有的东西,显然只适用于 COM 或 .NET 的东西.

#import is a Microsoft-specific thing, apparently for COM or .NET stuff only.

#include 是标准 C/C++ 预处理器语句,用于在源代码文件中包含头文件(或偶尔包含其他源代码).

#include is a standard C/C++ preprocessor statement, used for including header (or occasionally other source code) files in your source code file.

相关文章