Skip to content

Instantly share code, notes, and snippets.

@lennym
Created October 7, 2011 13:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lennym/1270328 to your computer and use it in GitHub Desktop.
Save lennym/1270328 to your computer and use it in GitHub Desktop.
Odd arguments behaviour in Google Chrome
function foo (val) {
console.log(arguments, arguments[0]);
val = 2;
}
foo(1);
// logs "[2], 1" in Google Chrome
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment