first commit

This commit is contained in:
s.golasch
2023-08-01 13:49:46 +02:00
commit 1fc239fd54
20238 changed files with 3112246 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
var TYPE = require('../../tokenizer').TYPE;
var IDENTIFIER = TYPE.Identifier;
var NUMBERSIGN = TYPE.NumberSign;
// '#' ident
module.exports = {
name: 'IdSelector',
structure: {
name: String
},
parse: function() {
this.scanner.eat(NUMBERSIGN);
return {
type: 'IdSelector',
loc: this.getLocation(this.scanner.tokenStart - 1, this.scanner.tokenEnd),
name: this.scanner.consume(IDENTIFIER)
};
},
generate: function(processChunk, node) {
processChunk('#');
processChunk(node.name);
}
};