Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1002411
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T07:49:43+00:00 2026-05-16T07:49:43+00:00

Is there a cl.exe option to dump all the pre-defined Macros ( along with

  • 0

Is there a cl.exe option to dump all the pre-defined Macros ( along with the defined values ).
Something like gcc -dM -E – < /dev/null for gcc.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T07:49:44+00:00Added an answer on May 16, 2026 at 7:49 am

    Unfortunately, I don’t think MSVC has a built in way of doing this.

    I’ve used the following program to dump values of ‘known’ predefined symbols. I should give attribution (because I know I didn’t come up with this), but I don’t have notes on where I got it from (update: looks like I probably got it from here: http://social.msdn.microsoft.com/Forums/en-US/vclanguage/thread/644c12ed-e3a7-4c5a-a73a-610fcc7913ca)…

    #define __STR2__(x) #x
    #define __STR1__(x) __STR2__(x)
    #define __PPOUT__(x) "#define " #x " " __STR1__(x)
    
    #if defined(_ATL_VER)
        #pragma message(__PPOUT__(_ATL_VER               ))
    #endif
    
    #if defined(_CHAR_UNSIGNED         )
        #pragma message(__PPOUT__(_CHAR_UNSIGNED         ))
    #endif
    
    #if defined(__CLR_VER              )
        #pragma message(__PPOUT__(__CLR_VER              ))
    #endif
    
    #if defined(__cplusplus_cli        )
        #pragma message(__PPOUT__(__cplusplus_cli        ))
    #endif
    
    #if defined(__COUNTER__            )
        #pragma message(__PPOUT__(__COUNTER__            ))
    #endif
    
    #if defined(__cplusplus            )
        #pragma message(__PPOUT__(__cplusplus            ))
    #endif
    
    #if defined(_CPPLIB_VER            )
        #pragma message(__PPOUT__(_CPPLIB_VER            ))
    #endif
    
    #if defined(_CPPRTTI               )
        #pragma message(__PPOUT__(_CPPRTTI               ))
    #endif
    
    #if defined(_CPPUNWIND             )
        #pragma message(__PPOUT__(_CPPUNWIND             ))
    #endif
    
    #if defined(_DEBUG                 )
        #pragma message(__PPOUT__(_DEBUG                 ))
    #endif
    
    #if defined(_DLL                   )
        #pragma message(__PPOUT__(_DLL                   ))
    #endif
    
    #if defined(__FUNCDNAME__          )
        #pragma message(__PPOUT__(__FUNCDNAME__          ))
    #endif
    
    #if defined(__FUNCSIG__            )
        #pragma message(__PPOUT__(__FUNCSIG__            ))
    #endif
    
    #if defined(__FUNCTION__           )
        #pragma message(__PPOUT__(__FUNCTION__           ))
    #endif
    
    #if defined(_INTEGRAL_MAX_BITS     )
        #pragma message(__PPOUT__(_INTEGRAL_MAX_BITS     ))
    #endif
    
    #if defined(_M_ALPHA               )
        #pragma message(__PPOUT__(_M_ALPHA               ))
    #endif
    
    #if defined(_M_CEE                 )
        #pragma message(__PPOUT__(_M_CEE                 ))
    #endif
    
    #if defined(_M_CEE_PURE            )
        #pragma message(__PPOUT__(_M_CEE_PURE            ))
    #endif
    
    #if defined(_M_CEE_SAFE            )
        #pragma message(__PPOUT__(_M_CEE_SAFE            ))
    #endif
    
    #if defined(_M_IX86                )
        #pragma message(__PPOUT__(_M_IX86                ))
    #endif
    
    #if defined(_M_IA64                )
        #pragma message(__PPOUT__(_M_IA64                ))
    #endif
    
    #if defined(_M_IX86_FP             )
        #pragma message(__PPOUT__(_M_IX86_FP             ))
    #endif
    
    #if defined(_M_MPPC                )
        #pragma message(__PPOUT__(_M_MPPC                ))
    #endif
    
    #if defined(_M_MRX000              )
        #pragma message(__PPOUT__(_M_MRX000              ))
    #endif
    
    #if defined(_M_PPC                 )
        #pragma message(__PPOUT__(_M_PPC                 ))
    #endif
    
    #if defined(_M_X64                 )
        #pragma message(__PPOUT__(_M_X64                 ))
    #endif
    
    #if defined(_MANAGED               )
        #pragma message(__PPOUT__(_MANAGED               ))
    #endif
    
    #if defined(_MFC_VER               )
        #pragma message(__PPOUT__(_MFC_VER               ))
    #endif
    
    #if defined(_MSC_BUILD             )
        #pragma message(__PPOUT__(_MSC_BUILD             ))
    #endif
    
    #if defined(_MSC_EXTENSIONS        )
        #pragma message(__PPOUT__(_MSC_EXTENSIONS        ))
    #endif
    
    #if defined(_MSC_FULL_VER          )
        #pragma message(__PPOUT__(_MSC_FULL_VER          ))
    #endif
    
    #if defined(_MSC_VER               )
        #pragma message(__PPOUT__(_MSC_VER               ))
    #endif
    
    #if defined(__MSVC_RUNTIME_CHECKS  )
        #pragma message(__PPOUT__(__MSVC_RUNTIME_CHECKS  ))
    #endif
    
    #if defined(_MT                    )
        #pragma message(__PPOUT__(_MT                    ))
    #endif
    
    #if defined(_NATIVE_WCHAR_T_DEFINED)
        #pragma message(__PPOUT__(_NATIVE_WCHAR_T_DEFINED))
    #endif
    
    #if defined(_OPENMP                )
        #pragma message(__PPOUT__(_OPENMP                ))
    #endif
    
    #if defined(_VC_NODEFAULTLIB       )
        #pragma message(__PPOUT__(_VC_NODEFAULTLIB       ))
    #endif
    
    #if defined(_WCHAR_T_DEFINED       )
        #pragma message(__PPOUT__(_WCHAR_T_DEFINED       ))
    #endif
    
    #if defined(_WIN32                 )
        #pragma message(__PPOUT__(_WIN32                 ))
    #endif
    
    #if defined(_WIN64                 )
        #pragma message(__PPOUT__(_WIN64                 ))
    #endif
    
    #if defined(_Wp64                  )
        #pragma message(__PPOUT__(_Wp64                  ))
    #endif
    
    void main() {}
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Is there anyway to combine all resources into a single exe file such as
The windows terminal (the user-interface around text-applications like cmd.exe) really sucks. There is so
Is there any option to copy some of the files (pre installation) to the
Is there an easy way to create standalone .exe files from Lua scripts? Basically
Is there a way in Delphi to get the currect application's exe size in
Is there a command-line argument that would force firefox.exe to launch a new process
Is there any way how to run the setup.exe bootstrapper generated by VS2008 with
Is there any way to enable execution-time variable expansion for cmd.exe (normally done by
The Compact Framework doesn't support Assembly.GetEntryAssembly to determine the launching .exe. So is there
In Microsoft SQL Server Management Studio 2008 there is a Generate scripts... option under

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.