Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 354721 - cannot parse static_cast inside loop statement
Summary: cannot parse static_cast inside loop statement
Status: RESOLVED INVALID
Alias: None
Product: CDT
Classification: Tools
Component: cdt-core (show other bugs)
Version: 8.0   Edit
Hardware: PC Linux
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact: Doug Schaefer CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-15 07:15 EDT by fengli CLA
Modified: 2011-08-16 09:43 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description fengli CLA 2011-08-15 07:15:00 EDT
Build Identifier: 

Below syntax cannot be parsed correctly, will report semantic error.
for (uint32 i = 0; i <
         static_cast<uint32>i;
         i++){
}

Upper is a pseudo code, the point is the static_cast keyword is not parsed correctly inside a for statement.

Reproducible: Always

Steps to Reproduce:
Below syntax cannot be parsed correctly, will report semantic error.
for (uint32 i = 0; i <
         static_cast<uint32>i;
         i++){
}

Upper is a pseudo code, the point is the static_cast keyword is not parsed correctly inside a for statement.
Comment 1 Markus Schorn CLA 2011-08-16 09:43:46 EDT
static_cast<xxx> requires parenthesis around its argument:
   static_case<uint32>(i)