JSDOC/TokenReader.js
[gnome.introspection-doc-generator] / JSDOC / TokenReader.js
index 9483adc..2f03c73 100644 (file)
@@ -78,12 +78,17 @@ TokenReader = XObject.define(
                     tokens.push(new Token(found, "KEYW", name));
                     return true;
                 }
-                if (found.indexOf('.') < 0 || !this.sepIdents) {
+                if (!this.sepIdents || found.indexOf('.') < 0 ) {
                     tokens.push(new Token(found, "NAME", "NAME"));
                     return true;
                 }
                 var n = found.split('.');
+                var p = false;
                 n.forEach(function(nm) {
+                    if (p) {
+                        tokens.push(new Token('.', "PUNC", "DOT"));
+                    }
+                    p=true;
                     tokens.push(new Token(nm, "NAME", "NAME"));
                 });
                 return true;