Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 354610

Summary: Override C/C++ locked file types
Product: [Tools] CDT Reporter: Ronald Posthumus <r.posthumus>
Component: cdt-codanAssignee: CDT Codan Inbox <cdt-codan-inbox>
Status: RESOLVED WORKSFORME QA Contact: Elena Laskavaia <elaskavaia.cdt>
Severity: enhancement    
Priority: P3 CC: cdtdoug, r.posthumus
Version: 8.0   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Ronald Posthumus CLA 2011-08-12 08:25:11 EDT
Build Identifier: 201105021546

My project is mixed language; assembler and c. It contains .inc files (assembler). In the preferences .inc files have status 'locked' in the file types preferences (C/C++->File Types) and are assigned to C Header file. The code analysis module treats these files as C header files instead as assembler include. This results in a lot of errors/warnings from the analysis module reported. I tried to overrule this behaviour in the following way:
Add .inc file with type 'assembly sources file' to the list of C/C++ file types --> no success.


It should be nice that this can be configured in some kind of way.

Reproducible: Always
Comment 1 Markus Schorn CLA 2011-08-16 09:31:46 EDT
Marking the bug as works for me, because you can override the file-types on project level. 
The fact that you cannot do that on workspace-level is a decision made by the platform.
Comment 2 Ronald Posthumus CLA 2011-08-16 09:49:32 EDT
(In reply to comment #1)
> Marking the bug as works for me, because you can override the file-types on
> project level. 
> The fact that you cannot do that on workspace-level is a decision made by the
> platform.

Thanks for the hint to override the file-types on project level. This works indeed; looked at the properties of the inc files and there is now assembler source file mentioned.

However, the code analysis module continues analyzing the *.inc files. SO the problems view still displays lots of semantic errors. Furthermore, syntax errors are displayed in the editor side bar for the *.inc files.
Comment 3 Markus Schorn CLA 2011-08-17 02:04:34 EDT
(In reply to comment #2)
> (In reply to comment #1)
> > Marking the bug as works for me, because you can override the file-types on
> > project level. 
> > The fact that you cannot do that on workspace-level is a decision made by the
> > platform.
This works for me, I had to manually delete the problem markers, though.
Comment 4 Ronald Posthumus CLA 2011-08-17 02:17:30 EDT
Manually deleting the problem markers and a restart of eclipse did work for me as well.