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.

Bug 240538 - Tool collection does not undefine macros that depends on compiler flag
Summary: Tool collection does not undefine macros that depends on compiler flag
Status: RESOLVED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Toolchain (show other bugs)
Version: 8.0
Hardware: PC Solaris
: P3 normal (vote)
Assignee: Alexander Simon
URL:
Keywords:
: 240545 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-01-16 11:22 UTC by Alexander Simon
Modified: 2014-01-23 02:38 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Simon 2014-01-16 11:22:06 UTC
C tool is cc (Oracle Solaris Studio compiler).
Code:

int main(int argc, char** argv) {
#ifdef __RESTRICT
#error "wrong model"
#endif
    return 0;
}

Code is compiled with additional flag -Xc:
cc -Xc  -c -g -o build/Debug/OracleSolarisStudio-Solaris-x86/newmain.o newmain.c

Code model stops parsing on error directive.
Comment 1 Quality Engineering 2014-01-17 02:46:54 UTC
Integrated into 'main-silver', will be available in build *201401170001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/3b0f0587bb76
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixing Bug #240538 Tool collection does not undefined macros that depends on compiler flag
- extend macros checker.
- fix Studio and GNU predefined macros
Comment 2 Quality Engineering 2014-01-18 04:50:13 UTC
Integrated into 'main-silver', will be available in build *201401180001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/d7a9be67e625
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixing Bug #240538 Tool collection does not undefined macros that depends on compiler flag
- fix macros equals "A=1" == "A"
Comment 3 Quality Engineering 2014-01-21 02:56:24 UTC
Integrated into 'main-silver', will be available in build *201401210001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/f544500e62af
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixing Bug #240538 Tool collection does not undefined macros that depends on compiler flag
- use important flags for detecting predefined paths and macros
Comment 4 Alexander Simon 2014-01-21 18:03:37 UTC
*** Bug 240545 has been marked as a duplicate of this bug. ***
Comment 5 Quality Engineering 2014-01-22 02:34:32 UTC
Integrated into 'main-silver', will be available in build *201401220001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/aae2ee367f02
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixing Bug #240538 Tool collection does not undefined macros that depends on compiler flag
- convert dwarf language to flag
Comment 6 Quality Engineering 2014-01-23 02:38:43 UTC
Integrated into 'main-silver', will be available in build *201401230001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/e9d0eef8651b
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixing Bug #240538 Tool collection does not undefined macros that depends on compiler flag
- -K PIC & -K pic can be important flags