Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Change regexps to match namespaced variables.

  • Loading branch information...
commit 96d28a326a07d4c83f39737348eded5e44a329d8 1 parent c13835e
@adamsanderson authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 lib/dox.js
View
8 lib/dox.js
@@ -233,7 +233,7 @@ exports.parseCodeContext = function(str){
, string: RegExp.$1 + '()'
};
// prototype method
- } else if (/^(\w+)\.prototype\.(\w+) *= *function/.exec(str)) {
+ } else if (/^([\w\.]+)\.prototype\.(\w+) *= *function/.exec(str)) {
return {
type: 'method'
, constructor: RegExp.$1
@@ -241,7 +241,7 @@ exports.parseCodeContext = function(str){
, string: RegExp.$1 + '.prototype.' + RegExp.$2 + '()'
};
// prototype property
- } else if (/^(\w+)\.prototype\.(\w+) *= *([^\n;]+)/.exec(str)) {
+ } else if (/^([\w\.]+)\.prototype\.(\w+) *= *([^\n;]+)/.exec(str)) {
return {
type: 'property'
, constructor: RegExp.$1
@@ -250,7 +250,7 @@ exports.parseCodeContext = function(str){
, string: RegExp.$1 + '.prototype' + RegExp.$2
};
// method
- } else if (/^(\w+)\.(\w+) *= *function/.exec(str)) {
+ } else if (/^([\w\.]+)\.(\w+) *= *function/.exec(str)) {
return {
type: 'method'
, receiver: RegExp.$1
@@ -258,7 +258,7 @@ exports.parseCodeContext = function(str){
, string: RegExp.$1 + '.' + RegExp.$2 + '()'
};
// property
- } else if (/^(\w+)\.(\w+) *= *([^\n;]+)/.exec(str)) {
+ } else if (/^([\w\.]+)\.(\w+) *= *([^\n;]+)/.exec(str)) {
return {
type: 'property'
, receiver: RegExp.$1
Please sign in to comment.
Something went wrong with that request. Please try again.