diff --git a/jsdoc b/jsdoc index 6f61c371..823fcab6 100755 --- a/jsdoc +++ b/jsdoc @@ -3,4 +3,6 @@ # rhino discards the path to the current script file, so we must add it back PWD=`pwd` BASEDIR=`dirname $0` -java -classpath ${BASEDIR}/lib/js.jar org.mozilla.javascript.tools.shell.Main -debug ${BASEDIR}/jsdoc.js --dirname=${PWD}/${BASEDIR} $@ \ No newline at end of file +java -classpath ${BASEDIR}/lib/js.jar org.mozilla.javascript.tools.shell.Main -debug ${BASEDIR}/jsdoc.js --dirname=${PWD}/${BASEDIR} $@ + +#java -classpath ${BASEDIR}/lib/js.jar org.mozilla.javascript.tools.debugger.Main -debug ${BASEDIR}/jsdoc.js --dirname=${PWD}/${BASEDIR} $@ \ No newline at end of file diff --git a/lib/require.js b/lib/require.js index 65423ea9..10432706 100644 --- a/lib/require.js +++ b/lib/require.js @@ -37,6 +37,8 @@ require._root.unshift(toDir(moduleUrl)); (function(__dirname) { + + /*debug*///var lineno=1;print('\n== '+moduleUrl+' ===============\n1'+moduleContent.replace(/(\n)/g, function(m, i){return '\n'+(++lineno);})); f.call({}, require, exports, module, __dirname); })(require._root[0]); require._root.shift(); diff --git a/package.json b/package.json index 599969ab..32069352 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "JSDoc", "version": "3.0.0alpha", - "revision": "1314647574958", + "revision": "1314689969938", "description": "An automatic documentation generator for javascript.", "keywords": [ "documentation", "javascript" ], "licenses": [ diff --git a/rhino_modules/jsdoc/name.js b/rhino_modules/jsdoc/name.js index 0c41cd6c..36f733c5 100644 --- a/rhino_modules/jsdoc/name.js +++ b/rhino_modules/jsdoc/name.js @@ -152,7 +152,7 @@ (longname.match( /^(:?(.+)([#.~]))?(.+?)$/ ) || []).reverse() : ['']; - var name = parts[0], + var name = parts[0] || '', // ensure name is always initialised to avoid error being thrown when calling replace on undefined [gh-24] scope = parts[1] || '', // ., ~, or # memberof = parts[2] || '', variation;