Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Marco Bubke
flatpak-qt-creator
Commits
b921489a
Commit
b921489a
authored
Oct 28, 2009
by
Roberto Raggi
Browse files
Process exception declarations.
parent
084d83a5
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/shared/cplusplus/CheckDeclaration.cpp
View file @
b921489a
...
...
@@ -263,8 +263,29 @@ bool CheckDeclaration::visit(AsmDefinitionAST *)
return
false
;
}
bool
CheckDeclaration
::
visit
(
ExceptionDeclarationAST
*
)
bool
CheckDeclaration
::
visit
(
ExceptionDeclarationAST
*
ast
)
{
FullySpecifiedType
ty
=
semantic
()
->
check
(
ast
->
type_specifier
,
_scope
);
FullySpecifiedType
qualTy
=
ty
.
qualifiedType
();
Name
*
name
=
0
;
FullySpecifiedType
declTy
=
semantic
()
->
check
(
ast
->
declarator
,
qualTy
,
_scope
,
&
name
);
unsigned
location
=
locationOfDeclaratorId
(
ast
->
declarator
);
if
(
!
location
)
{
if
(
ast
->
declarator
)
location
=
ast
->
declarator
->
firstToken
();
else
location
=
ast
->
firstToken
();
}
Declaration
*
symbol
=
control
()
->
newDeclaration
(
location
,
name
);
symbol
->
setStartOffset
(
tokenAt
(
ast
->
firstToken
()).
offset
);
symbol
->
setEndOffset
(
tokenAt
(
ast
->
lastToken
()).
offset
);
symbol
->
setType
(
declTy
);
_scope
->
enterSymbol
(
symbol
);
return
false
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment