This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Hi i find at parsing process. I use cnd-060615-linux.bin + netbeans-5_5-beta-linux.bin. As i can understand exception appeared at parsing # if ULONG_MAX == 18446744073709551615 java dont understand number 18446744073709551615, or 18446744073709551615UL ps: it is not my code, it from BOOST library.
Created attachment 31682 [details] netbeans 5.5b log file
problem reproduced.
For Number exception we should check correctly strings, but for now: - workaround. Use Long.MAX_VALUE for overflow values.
The problem occurs when 64-bit integer value appears in preprocessor conditional directive. Java integer data types aren't large enough to store such values. No exception is thrown. The remaining problem is that some conditionals might be evaluated incorrectly and thus incorrect conditional branch would be parsed. The given example from boost works as it should. The example that doesn't work correct is: #if __LONG_LONG_MAX__ < 18446744073709551615 void foo32() { } #else void foo64() { } #endif On 32-bit system, it should contain foo32(). Now code model reports foo64().
Escalated to P2
The original problem is resolved. For boost with example like #if __LONG_LONG_MAX__ == 18446744073709551615 void foo64() { } #else void foo32() { } #endif no any exception and platform is detected correctly
the testcase of vkvashin is handled in http://www.netbeans.org/issues/show_bug.cgi?id=137578