We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
getQualifiedName
1 parent 68a661f commit 754fd8eCopy full SHA for 754fd8e
go/ql/lib/semmle/go/Scopes.qll
@@ -113,7 +113,9 @@ class Entity extends @object {
113
114
/** Gets the qualified name of this entity, if any. */
115
string getQualifiedName() {
116
- exists(string pkg, string name | this.hasQualifiedName(pkg, name) | result = pkg + "." + name)
+ exists(string pkg, string name | this.hasQualifiedName(pkg, name) |
117
+ if pkg = "" then result = name else result = pkg + "." + name
118
+ )
119
}
120
121
/**
0 commit comments