This issue mimics #63 for function table declarations. The production is given in section 5.6 of the specification as follows:
var x:Identifier = [ f0:Identifier (, f:Identifier) ... ] ;
(I've added parentheses in the metalanguage, on the assumption that the postfix ellipsis notation used throughout the specification denotes the operand's Kleene closure.)
However, OdinMonkey's validator accepts comma-separated function table declarations of the form:
var x0:Identifier = [ f0:Identifier (, f0′:Identifier) ... ] (, x1:Identifier = [ f1:Identifier (, f1′:Identifier) ... ]) ... ;
Consider, for example, the following valid module:
(function() {
"use asm"
function f() {}
function g() {}
var x = [f], y = [g], z = [f, g]
return f
})
This issue mimics #63 for function table declarations. The production is given in section 5.6 of the specification as follows:
(I've added parentheses in the metalanguage, on the assumption that the postfix ellipsis notation used throughout the specification denotes the operand's Kleene closure.)
However, OdinMonkey's validator accepts comma-separated function table declarations of the form:
Consider, for example, the following valid module: