ether-code 0.4.2 → 0.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cli/ether.js +1 -1
- package/ether-parser.js +9 -2
- package/package.json +1 -1
package/cli/ether.js
CHANGED
package/ether-parser.js
CHANGED
|
@@ -81,7 +81,7 @@ class EtherParser {
|
|
|
81
81
|
expect(type) {
|
|
82
82
|
const token = this.current()
|
|
83
83
|
if (!token || token.type !== type) {
|
|
84
|
-
throw new Error(`Attendu ${type},
|
|
84
|
+
throw new Error(`Attendu ${type}, reçu ${token ? token.type : 'EOF'}`)
|
|
85
85
|
}
|
|
86
86
|
return this.advance()
|
|
87
87
|
}
|
|
@@ -306,7 +306,14 @@ class EtherParser {
|
|
|
306
306
|
break
|
|
307
307
|
}
|
|
308
308
|
|
|
309
|
-
if (token.type === TokenType.
|
|
309
|
+
if (token.type === TokenType.DOUBLE_COLON) {
|
|
310
|
+
this.advance()
|
|
311
|
+
const pseudoName = this.current()
|
|
312
|
+
if (pseudoName && pseudoName.type === TokenType.IDENTIFIER) {
|
|
313
|
+
parts.push('::' + pseudoName.value)
|
|
314
|
+
this.advance()
|
|
315
|
+
}
|
|
316
|
+
} else if (token.type === TokenType.COLON) {
|
|
310
317
|
this.advance()
|
|
311
318
|
const next = this.current()
|
|
312
319
|
if (next && next.type === TokenType.COLON) {
|