fix: /// <reference path="..." static='true' />

The second quote of the static attribute was incorrectly
matched against the first quote of the path attribute.
This commit is contained in:
Adam Freidin
2014-08-11 10:38:41 -07:00
parent c71e596ba8
commit 988cec595d
+1 -1
View File
@@ -49,7 +49,7 @@ module TypeScript {
return isNoDefaultLibRegex.exec(comment);
}
export var tripleSlashReferenceRegExp = /^(\/\/\/\s*<reference\s+path=)('|")(.+?)\2\s*(static=('|")(.+?)\2\s*)*\/>/;
export var tripleSlashReferenceRegExp = /^(\/\/\/\s*<reference\s+path=)('|")(.+?)\2\s*(static=('|")(.+?)\5\s*)*\/>/;
function getFileReferenceFromReferencePath(fileName: string, text: ISimpleText, position: number, comment: string, diagnostics: Diagnostic[]): IFileReference {
// First, just see if they've written: /// <reference\s+