简体   繁体   中英

Is there a way to create Visual Assist specific preprocessor sections?

I have some complicated preprocessor macros which use the N-arg trick to count arguments and generate specific sub macro depending on the __VA_ARG__ argument count. Visual Assist doesn't like that and it completely messes up the parsing and the error reports. I would like to know if any predefined macros (for example __VAX__ or __VISUAL_ASSIST__ ) are defined in case of Visual assist parsing to implement specific code for him. If not, do you know any other way to avoid visual assist parsing a section or a way to give it a specific version of a macro ?

You can give Visual Assist a specific version of a macro by creating a va_stdafx.h file. Inside this file place the simplified macro definitions you wish Visual Assist to see. Ensure the file ends with a blank line.

The process is described here: https://support.wholetomato.com/default.asp?W302

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM