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:
f2ea858
)
JSDOC/Parser.js
author
Alan Knowles
<alan@akbkhome.com>
Mon, 28 Jun 2010 07:54:41 +0000
(15:54 +0800)
committer
Alan Knowles
<alan@akbkhome.com>
Mon, 28 Jun 2010 07:54:41 +0000
(15:54 +0800)
JSDOC/Parser.js
patch
|
blob
|
history
diff --git
a/JSDOC/Parser.js
b/JSDOC/Parser.js
index
75e4c9d
..
5f5c594
100644
(file)
--- a/
JSDOC/Parser.js
+++ b/
JSDOC/Parser.js
@@
-1,6
+1,6
@@
//<script type="text/javascript">
//<script type="text/javascript">
-Walker = imports.Walker
.Walker
;
+Walker = imports.Walker
2.Walker2
;
Symbol = imports.Symbol.Symbol;
DocComment = imports.DocComment.DocComment;
Options = imports.Options.Options;
Symbol = imports.Symbol.Symbol;
DocComment = imports.DocComment.DocComment;
Options = imports.Options.Options;
@@
-61,16
+61,16
@@
Parser = {
// not a nice way to set stuff...
// not a nice way to set stuff...
-
JSDOC.
Symbol.srcFile = (srcFile || "");
-
JSDOC.
DocComment.shared = ""; // shared comments don't cross file boundaries
+ Symbol.srcFile = (srcFile || "");
+ DocComment.shared = ""; // shared comments don't cross file boundaries
- this.filesSymbols[
JSDOC.Symbol.srcFile] = new JSDOC.
SymbolSet();
+ this.filesSymbols[
Symbol.srcFile] = new
SymbolSet();
- this.walker = new
JSDOC.
Walker2(ts);
+ this.walker = new
Walker2(ts);
this.walker.buildSymbolTree()
//this.walker.walk(ts); // adds to our symbols
// throw "done sym tree";
this.walker.buildSymbolTree()
//this.walker.walk(ts); // adds to our symbols
// throw "done sym tree";
@@
-84,10
+84,10
@@
Parser = {
if (symbol.is("FILE") || symbol.is("GLOBAL")) {
continue;
}
if (symbol.is("FILE") || symbol.is("GLOBAL")) {
continue;
}
- else if (!
JSDOC.opt
.a && !symbol.comment.isUserComment) {
+ else if (!
Options
.a && !symbol.comment.isUserComment) {
//print("Deleting Symbols (no a / user comment): " + symbol.alias);
//this.symbols.deleteSymbol(symbol.alias);
//print("Deleting Symbols (no a / user comment): " + symbol.alias);
//this.symbols.deleteSymbol(symbol.alias);
- //this.filesSymbols[
JSDOC.
Symbol.srcFile].deleteSymbol(symbol.alias);
+ //this.filesSymbols[Symbol.srcFile].deleteSymbol(symbol.alias);
}
if (/#$/.test(symbol.alias)) { // we don't document prototypes - this should not happen..
}
if (/#$/.test(symbol.alias)) { // we don't document prototypes - this should not happen..
@@
-97,18
+97,18
@@
Parser = {
print("Renaming Symbol (got a #): " + symbol.alias);
var n = '' + symbol.alias;
this.symbols.renameSymbol( n ,n.substring(0,n-1));
print("Renaming Symbol (got a #): " + symbol.alias);
var n = '' + symbol.alias;
this.symbols.renameSymbol( n ,n.substring(0,n-1));
- this.filesSymbols[
JSDOC.
Symbol.srcFile].renameSymbol( n ,n.substring(0,n-1));
+ this.filesSymbols[Symbol.srcFile].renameSymbol( n ,n.substring(0,n-1));
continue;
}
*/
print("Deleting Symbols (got a #): " + symbol.alias);
this.symbols.deleteSymbol(symbol.alias);
continue;
}
*/
print("Deleting Symbols (got a #): " + symbol.alias);
this.symbols.deleteSymbol(symbol.alias);
- this.filesSymbols[
JSDOC.
Symbol.srcFile].deleteSymbol(symbol.alias);
+ this.filesSymbols[Symbol.srcFile].deleteSymbol(symbol.alias);
}
}
}
}
- //print(
JSDOC.prettyDump(JSDOC.toQDump(this.filesSymbols[JSDOC.
Symbol.srcFile]._index,'{','}')));
+ //print(
prettyDump(toQDump(this.filesSymbols[
Symbol.srcFile]._index,'{','}')));
//print("AfterParse: " + this.symbols.keys().toSource().split(",").join(",\n "));
return this.symbols.toArray();
},
//print("AfterParse: " + this.symbols.keys().toSource().split(",").join(",\n "));
return this.symbols.toArray();
},
@@
-124,7
+124,7
@@
Parser = {
if (oldSymbol.comment.isUserComment && !oldSymbol.comment.hasTags) {
if (symbol.comment.isUserComment) { // old and new are both documented
if (oldSymbol.comment.isUserComment && !oldSymbol.comment.hasTags) {
if (symbol.comment.isUserComment) { // old and new are both documented
-
JSDOC.opt
.LOG.warn("The symbol '"+symbol.alias+"' is documented more than once.");
+
Options
.LOG.warn("The symbol '"+symbol.alias+"' is documented more than once.");
}
else { // old is documented but new isn't
return;
}
else { // old is documented but new isn't
return;
@@
-141,13
+141,13
@@
Parser = {
}
// -p flag is required to document private things
}
// -p flag is required to document private things
- if ((symbol.isInner || symbol.isPrivate) && !
JSDOC.opt
.p) return;
+ if ((symbol.isInner || symbol.isPrivate) && !
Options
.p) return;
// ignored things are not documented, this doesn't cascade
if (symbol.isIgnored) return;
// add it to the file's list... (for dumping later..)
// ignored things are not documented, this doesn't cascade
if (symbol.isIgnored) return;
// add it to the file's list... (for dumping later..)
- if (
JSDOC.
Symbol.srcFile) {
- this.filesSymbols[
JSDOC.
Symbol.srcFile].addSymbol(symbol);
+ if (Symbol.srcFile) {
+ this.filesSymbols[Symbol.srcFile].addSymbol(symbol);
}
this.symbols.addSymbol(symbol);
}
this.symbols.addSymbol(symbol);
@@
-155,7
+155,7
@@
Parser = {
addBuiltin: function(name) {
addBuiltin: function(name) {
- var builtin = new
JSDOC.Symbol(name, [], "CONSTRUCTOR", new JSDOC.
DocComment(""));
+ var builtin = new
Symbol(name, [], "CONSTRUCTOR", new
DocComment(""));
builtin.isNamespace = false;
builtin.srcFile = "";
builtin.isPrivate = false;
builtin.isNamespace = false;
builtin.srcFile = "";
builtin.isPrivate = false;