How to check if compiler is C++ and a /clr compiler option is set in C++

1 Answer

0 votes
#include <stdio.h>

int main() {
#ifdef __cplusplus_cli
    printf("%d\n", __cplusplus_cli);
#else
    printf("not cplusplus_cli\n");
#endif
}





/*
run:

not cplusplus_cli

*/

 



answered Apr 21, 2022 by avibootz

Related questions

1 answer 294 views
294 views asked Apr 22, 2022 by avibootz
1 answer 225 views
225 views asked Apr 22, 2022 by avibootz
1 answer 233 views
233 views asked Apr 22, 2022 by avibootz
1 answer 258 views
1 answer 232 views
232 views asked Apr 22, 2022 by avibootz
1 answer 336 views
2 answers 327 views
...