tc39 / Function-prototype-toString-revision

:fishing_pole_and_fish: ECMA-262 proposal to update Function.prototype.toString
https://tc39.github.io/Function-prototype-toString-revision
26 stars 10 forks source link

[Question] Does this proposal guarantees that parameters names match the source? #35

Closed nicolo-ribaudo closed 5 years ago

nicolo-ribaudo commented 5 years ago
function fn(foo) {}

Can an engine return function fn(a) {} for fn.toString()?

michaelficarra commented 5 years ago

The parameter names are part of the source text matched by the function, so they are preserved.