Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Tobias Hunger
qt-creator
Commits
86a8812b
Commit
86a8812b
authored
Nov 10, 2009
by
Roberto Raggi
Browse files
Removed ObjCSynthesizedPropertyAST
Done with Erik Verbruggen
parent
4c246763
Changes
5
Hide whitespace changes
Inline
Side-by-side
src/shared/cplusplus/AST.cpp
View file @
86a8812b
...
...
@@ -2207,25 +2207,6 @@ unsigned ObjCSynthesizedPropertyAST::lastToken() const
return
property_identifier
+
1
;
}
unsigned
ObjCSynthesizedPropertyListAST
::
firstToken
()
const
{
if
(
synthesized_property
)
return
synthesized_property
->
firstToken
();
// ### assert?
return
0
;
}
unsigned
ObjCSynthesizedPropertyListAST
::
lastToken
()
const
{
for
(
const
ObjCSynthesizedPropertyListAST
*
it
=
this
;
it
;
it
=
it
->
next
)
{
if
(
!
it
->
next
&&
it
->
synthesized_property
)
{
return
it
->
synthesized_property
->
lastToken
();
}
}
// ### assert?
return
0
;
}
unsigned
ObjCSynthesizedPropertiesDeclarationAST
::
firstToken
()
const
{
return
synthesized_token
;
...
...
src/shared/cplusplus/AST.h
View file @
86a8812b
...
...
@@ -2502,22 +2502,6 @@ protected:
virtual
void
accept0
(
ASTVisitor
*
visitor
);
};
class
CPLUSPLUS_EXPORT
ObjCSynthesizedPropertyListAST
:
public
AST
{
public:
ObjCSynthesizedPropertyAST
*
synthesized_property
;
ObjCSynthesizedPropertyListAST
*
next
;
public:
virtual
ObjCSynthesizedPropertyListAST
*
asObjCSynthesizedPropertyList
()
{
return
this
;
}
virtual
unsigned
firstToken
()
const
;
virtual
unsigned
lastToken
()
const
;
protected:
virtual
void
accept0
(
ASTVisitor
*
visitor
);
};
class
CPLUSPLUS_EXPORT
ObjCSynthesizedPropertiesDeclarationAST
:
public
DeclarationAST
{
public:
...
...
src/shared/cplusplus/ASTVisit.cpp
View file @
86a8812b
...
...
@@ -1098,14 +1098,6 @@ void ObjCSynthesizedPropertyAST::accept0(ASTVisitor *visitor)
visitor
->
endVisit
(
this
);
}
void
ObjCSynthesizedPropertyListAST
::
accept0
(
ASTVisitor
*
visitor
)
{
if
(
visitor
->
visit
(
this
))
{
accept
(
synthesized_property
,
visitor
);
}
visitor
->
endVisit
(
this
);
}
void
ObjCSynthesizedPropertiesDeclarationAST
::
accept0
(
ASTVisitor
*
visitor
)
{
if
(
visitor
->
visit
(
this
))
{
...
...
src/shared/cplusplus/ASTfwd.h
View file @
86a8812b
...
...
@@ -148,7 +148,6 @@ class ObjCSelectorWithoutArgumentsAST;
class
ObjCSynchronizedStatementAST
;
class
ObjCSynthesizedPropertiesDeclarationAST
;
class
ObjCSynthesizedPropertyAST
;
class
ObjCSynthesizedPropertyListAST
;
class
ObjCTypeNameAST
;
class
ObjCVisibilityDeclarationAST
;
class
OperatorAST
;
...
...
@@ -201,6 +200,7 @@ typedef List<ObjCMessageArgumentAST *> ObjCMessageArgumentListAST;
typedef
List
<
ObjCSelectorArgumentAST
*>
ObjCSelectorArgumentListAST
;
typedef
List
<
ObjCPropertyAttributeAST
*>
ObjCPropertyAttributeListAST
;
typedef
List
<
ObjCMessageArgumentDeclarationAST
*>
ObjCMessageArgumentDeclarationListAST
;
typedef
List
<
ObjCSynthesizedPropertyAST
*>
ObjCSynthesizedPropertyListAST
;
typedef
ExpressionListAST
TemplateArgumentListAST
;
...
...
src/shared/cplusplus/Parser.cpp
View file @
86a8812b
...
...
@@ -4577,13 +4577,13 @@ bool Parser::parseObjCMethodDefinitionList(DeclarationListAST *&node)
ast
->
synthesized_token
=
consumeToken
();
ObjCSynthesizedPropertyListAST
*
last
=
new
(
_pool
)
ObjCSynthesizedPropertyListAST
;
ast
->
property_identifiers
=
last
;
last
->
synthesized_property
=
new
(
_pool
)
ObjCSynthesizedPropertyAST
;
match
(
T_IDENTIFIER
,
&
(
last
->
synthesized_property
->
property_identifier
));
last
->
value
=
new
(
_pool
)
ObjCSynthesizedPropertyAST
;
match
(
T_IDENTIFIER
,
&
(
last
->
value
->
property_identifier
));
if
(
LA
()
==
T_EQUAL
)
{
last
->
synthesized_property
->
equals_token
=
consumeToken
();
last
->
value
->
equals_token
=
consumeToken
();
match
(
T_IDENTIFIER
,
&
(
last
->
synthesized_property
->
property_alias_identifier
));
match
(
T_IDENTIFIER
,
&
(
last
->
value
->
property_alias_identifier
));
}
while
(
LA
()
==
T_COMMA
)
{
...
...
@@ -4592,13 +4592,13 @@ bool Parser::parseObjCMethodDefinitionList(DeclarationListAST *&node)
last
->
next
=
new
(
_pool
)
ObjCSynthesizedPropertyListAST
;
last
=
last
->
next
;
last
->
synthesized_property
=
new
(
_pool
)
ObjCSynthesizedPropertyAST
;
match
(
T_IDENTIFIER
,
&
(
last
->
synthesized_property
->
property_identifier
));
last
->
value
=
new
(
_pool
)
ObjCSynthesizedPropertyAST
;
match
(
T_IDENTIFIER
,
&
(
last
->
value
->
property_identifier
));
if
(
LA
()
==
T_EQUAL
)
{
last
->
synthesized_property
->
equals_token
=
consumeToken
();
last
->
value
->
equals_token
=
consumeToken
();
match
(
T_IDENTIFIER
,
&
(
last
->
synthesized_property
->
property_alias_identifier
));
match
(
T_IDENTIFIER
,
&
(
last
->
value
->
property_alias_identifier
));
}
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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