Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 2792 for code


Ignore:
Timestamp:
Mar 16, 2009, 10:42:09 PM (16 years ago)
Author:
rgrieder
Message:

Finally found the MSVC IntelliSense bug! It wasn't working at all, so there was helping information about any symbol, class, function or macro. That was very annoying…
Turned out the compiler likes "-" to start a compiler switch, but IntelliSense doesn't like that at all. Using "/" instead.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/cmake/FlagUtilities.cmake

    r2710 r2792  
    5454ENDMACRO(SET_CACHE)
    5555
     56# Visual studio (esp. IntelliSense) doesn't like dashes to specify arguments
     57# Always use foward slashes instead
     58IF(MSVC)
     59  SET(ARGUMENT_STARTER "/")
     60ELSE()
     61  SET(ARGUMENT_STARTER "-")
     62ENDIF(MSVC)
     63
    5664# Separates a string of flags. " -" or " /" denotes the start of a flag.
    5765# The same sequence inside double quotation marks is ignored.
     
    7179    # Extract one flag if possible
    7280    SET(_flag)
    73     STRING(REGEX REPLACE "^.* [/-](.+)( [/-].*$)" "-\\1" _flag "${_flag_string}")
     81    STRING(REGEX REPLACE "^.* [/-](.+)( [/-].*$)" "${ARGUMENT_STARTER}\\1" _flag "${_flag_string}")
    7482    STRING(REGEX REPLACE "^.* [/-](.+)( [/-].*$)" "\\2"  _flag_string "${_flag_string}")
    7583    IF(NOT _flag STREQUAL _flag_string)
Note: See TracChangeset for help on using the changeset viewer.