projects
/
gnome.introspection-doc-generator
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
1af418b
)
JSDOC/ScopeParser.vala
author
Alan Knowles
<alan@roojs.com>
Fri, 6 Nov 2015 08:57:47 +0000
(16:57 +0800)
committer
Alan Knowles
<alan@roojs.com>
Fri, 6 Nov 2015 08:57:47 +0000
(16:57 +0800)
JSDOC/ScopeParser.vala
patch
|
blob
|
history
diff --git
a/JSDOC/ScopeParser.vala
b/JSDOC/ScopeParser.vala
index
38e73ab
..
05d7be7
100644
(file)
--- a/
JSDOC/ScopeParser.vala
+++ b/
JSDOC/ScopeParser.vala
@@
-901,8
+901,8
@@
namespace JSDOC {
//assert token.getType() == Token.NAME ||
// token.getType() == Token.COMMA;
if (token.type == "NAME" && this.mode == ScopeParserMode.BUILDING_SYMBOL_TREE) {
//assert token.getType() == Token.NAME ||
// token.getType() == Token.COMMA;
if (token.type == "NAME" && this.mode == ScopeParserMode.BUILDING_SYMBOL_TREE) {
- symbol = token.data;
- identifier = fnScope.declareIdentifier(symbol,token);
+
var
symbol = token.data;
+
var
identifier = fnScope.declareIdentifier(symbol,token);
if (symbol == "$super" && argpos == 0) {
// Exception for Prototype 1.6...
identifier.preventMunging();
if (symbol == "$super" && argpos == 0) {
// Exception for Prototype 1.6...
identifier.preventMunging();
@@
-921,11
+921,9
@@
namespace JSDOC {
//token = this.ts.nextTok();
//print(token.toString());
var outTS = this.ts;
//token = this.ts.nextTok();
//print(token.toString());
var outTS = this.ts;
- var _this = this;
- token.items.forEach(function(tar) {
- _this.ts = new TokenStream(tar);
- _this.parseScope(fnScope);
-
+ foreach(var tar in token.items) {
+ this.ts = new TokenStream(tar);
+ this.parseScope(fnScope);
});
});
@@
-938,9
+936,9
@@
namespace JSDOC {
//print("ENDFN -1: " + this.ts.lookTok(-1).toString());
//print("ENDFN 0: " + this.ts.lookTok(0).toString());
//print("ENDFN 1: " + this.ts.lookTok(1).toString());
//print("ENDFN -1: " + this.ts.lookTok(-1).toString());
//print("ENDFN 0: " + this.ts.lookTok(0).toString());
//print("ENDFN 1: " + this.ts.lookTok(1).toString());
- }
,
+ }
-
protectScopeFromObfuscation : function
(scope) {
+
void protectScopeFromObfuscation
(scope) {
//assert scope != null;
if (scope == this.globalScope) {
//assert scope != null;
if (scope == this.globalScope) {
@@
-958,9
+956,9
@@
namespace JSDOC {
scope.preventMunging();
},
scope.preventMunging();
},
-
getIdentifier: function
(symbol, scope, token) {
+
string getIdentifier
(symbol, scope, token) {
var identifier;
var identifier;
- while (scope !=
false
) {
+ while (scope !=
null
) {
identifier = scope.getIdentifier(symbol, token);
//println("ScopeParser.getIdentgetUsedSymbols("+symbol+")=" + scope.getUsedSymbols().join(','));
if (identifier) {
identifier = scope.getIdentifier(symbol, token);
//println("ScopeParser.getIdentgetUsedSymbols("+symbol+")=" + scope.getUsedSymbols().join(','));
if (identifier) {
@@
-968,6
+966,6
@@
namespace JSDOC {
}
scope = scope.parent;
}
}
scope = scope.parent;
}
- return
false
;
+ return
""
;
}
};
}
};