Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 324150 - LR Parser's action class CPPBuildASTParserAction throws UnsupportedOperationException by its function consumeDeclarationSimple.
Summary: LR Parser's action class CPPBuildASTParserAction throws UnsupportedOperationE...
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-parser (show other bugs)
Version: 7.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 7.0.1   Edit
Assignee: Project Inbox CLA
QA Contact: Mike Kucera CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-08-31 18:26 EDT by John Liu CLA
Modified: 2010-10-26 12:01 EDT (History)
1 user (show)

See Also:


Attachments
A fix patch applied to org.eclipse.cdt.core.lrparser (2.43 KB, text/plain)
2010-08-31 18:44 EDT, John Liu CLA
recoskie: iplog+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description John Liu CLA 2010-08-31 18:26:08 EDT
Build Identifier: 

LR Parser's action class CPPBuildASTParserAction throws UnsupportedOperationException by its function consumeDeclarationSimple.

This is caused by Collections.emptyList() used by the function tried to add a an entry, but it doesn't support add operation.

Reproducible: Always
Comment 1 John Liu CLA 2010-08-31 18:44:21 EDT
Created attachment 177900 [details]
A fix patch applied to org.eclipse.cdt.core.lrparser
Comment 2 John Liu CLA 2010-08-31 18:45:24 EDT
The fix patch will target 701 and head stream.
Comment 3 Chris Recoskie CLA 2010-09-01 09:42:14 EDT
Applied to cdt_7_0 and HEAD.
Comment 4 Mike Kucera CLA 2010-09-01 10:02:31 EDT
I think this bug has popped up a couple times now. Might be a good idea to replace all uses of Collections.emptyList() in the actions to ensure it doesn't happen again.
Comment 5 John Liu CLA 2010-09-01 10:12:26 EDT
(In reply to comment #4)
> I think this bug has popped up a couple times now. Might be a good idea to
> replace all uses of Collections.emptyList() in the actions to ensure it doesn't
> happen again.

Thanks, Mike. 

I check my workspace and there is no more parser action function uses it.
Comment 7 John Liu CLA 2010-10-26 12:01:28 EDT
This is fixed.