You are reading a single comment by @mrQ and its replies.
Click here to read the full conversation.
-
at least some hint in the API doc (http://www.espruino.com/Reference#l__global_arguments) would be fine.
at least some hint in the API doc (http://www.espruino.com/Reference#l__global_arguments) would be fine.
Thanks for letting me know! I put a bug in for it here: https://github.com/espruino/Espruino/issues/1321
You probably gathered already but it's because you specified an argument
p1
. Espruino doesn't keep a second arguments array for the sake of saving memory, so it reconstructs the array when you ask for it.I think probably the sensible option for now is just to document this difference in the reference for
arguments
?I guess there should probably be a page for known differences to the ES5 spec, like the newline handling and lack of unicode