parserlib: skip spaces before "," in @document foo() , bar()
This commit is contained in:
parent
56a8212fdf
commit
3d0b733e9a
|
@ -4326,13 +4326,8 @@ self.parserlib = (() => {
|
||||||
_document() {
|
_document() {
|
||||||
const stream = this._tokenStream;
|
const stream = this._tokenStream;
|
||||||
const functions = [];
|
const functions = [];
|
||||||
let prefix = '';
|
|
||||||
|
|
||||||
const start = stream.mustMatch(Tokens.DOCUMENT_SYM);
|
const start = stream.mustMatch(Tokens.DOCUMENT_SYM);
|
||||||
if (/^@-([^-]+)-/.test(start.value)) {
|
const prefix = start.value.split('-')[1] || '';
|
||||||
prefix = RegExp.$1;
|
|
||||||
}
|
|
||||||
|
|
||||||
do {
|
do {
|
||||||
this._ws();
|
this._ws();
|
||||||
functions.push(this._documentFunction());
|
functions.push(this._documentFunction());
|
||||||
|
@ -4373,9 +4368,12 @@ self.parserlib = (() => {
|
||||||
|
|
||||||
_documentFunction() {
|
_documentFunction() {
|
||||||
const stream = this._tokenStream;
|
const stream = this._tokenStream;
|
||||||
return stream.match(Tokens.URI) ?
|
if (stream.match(Tokens.URI)) {
|
||||||
new PropertyValuePart(stream._token) :
|
const res = new PropertyValuePart(stream._token);
|
||||||
this._function();
|
this._ws();
|
||||||
|
return res;
|
||||||
|
}
|
||||||
|
return this._function();
|
||||||
}
|
}
|
||||||
|
|
||||||
_operator(inFunction) {
|
_operator(inFunction) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user