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
Marco Bubke
flatpak-qt-creator
Commits
469b6ef7
Commit
469b6ef7
authored
May 14, 2010
by
Roberto Raggi
Browse files
Get rid of useless overload of findType().
parent
31135d57
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/libs/cplusplus/LookupContext.cpp
View file @
469b6ef7
...
...
@@ -218,18 +218,7 @@ QList<Symbol *> LookupContext::lookup(const Name *name, Scope *scope) const
break
;
// it's a formal argument.
if
(
fun
->
name
()
&&
fun
->
name
()
->
isQualifiedNameId
())
{
const
QualifiedNameId
*
q
=
fun
->
name
()
->
asQualifiedNameId
();
QList
<
const
Name
*>
path
=
fullyQualifiedName
(
scope
->
owner
());
for
(
unsigned
index
=
0
;
index
<
q
->
nameCount
()
-
1
;
++
index
)
{
// ### TODO remove me.
const
Name
*
name
=
q
->
nameAt
(
index
);
if
(
name
->
isNameId
()
||
name
->
isTemplateNameId
())
path
.
append
(
name
);
}
if
(
ClassOrNamespace
*
binding
=
bindings
()
->
lookupType
(
path
))
if
(
ClassOrNamespace
*
binding
=
bindings
()
->
lookupType
(
fun
))
return
binding
->
lookup
(
name
);
}
...
...
@@ -647,12 +636,6 @@ ClassOrNamespace *CreateBindings::lookupType(Symbol *symbol)
return
b
;
}
ClassOrNamespace
*
CreateBindings
::
lookupType
(
const
QList
<
const
Name
*>
&
path
)
{
ClassOrNamespace
*
e
=
_globalNamespace
->
findType
(
path
);
return
e
;
}
void
CreateBindings
::
process
(
Symbol
*
s
,
ClassOrNamespace
*
classOrNamespace
)
{
ClassOrNamespace
*
previous
=
switchCurrentClassOrNamespace
(
classOrNamespace
);
...
...
src/libs/cplusplus/LookupContext.h
View file @
469b6ef7
...
...
@@ -126,10 +126,6 @@ public:
/// Finds the binding associated to the given symbol.
ClassOrNamespace
*
lookupType
(
Symbol
*
symbol
);
/// Find the binding with the given path.
/// \internal
ClassOrNamespace
*
lookupType
(
const
QList
<
const
Name
*>
&
path
);
/// Returns the Control that must be used to create temporary symbols.
/// \internal
Control
*
control
()
const
;
...
...
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