Soda: S/optizer/optimizer/ # though “optizer” is an appealying word
Mastropietro: Functiona { a = 3; return arguments; }1, 2, 3
Gerrero: Mastropietro: object {0: 3, 1: 2, 2: 3, callee: function a { a = 3; return arguments; }, length: 3}
Mastropietro: Notice the weird referencing of a number variable
Mastropietro: The arguments object is changed by the changing of a local variable
Mastropietro: According to https://github.com/petkaantonov/bluebird/wiki/Optimization-killers#3-managing-arguments using the arguments object outside of the function results in memory leaks
Mastropietro: When you call slice with arguments, its doing that
Thruman: Mastropietro: it’s not a memory leak.
Devonshire: Mastropietro: it’s talking about leaking implementation details outside of particular optimisation scopes.
Plungy: Mastropietro: the point is if you avoid p***ing the arguments object to code that can’t be reasoned about statically, it might not be able to optimise away the object itself.
Mastropietro: I’d like to know as well exactly how the optimizer is killed
Mastropietro: In most implementations
Mastropietro: Oh I see, that makes sense
Onsurez: Arguments objects have a bunch of really weird semantics, including the ability to modify variables created by the parameters.
Sedano: So it’s better to make sure the implementation doesn’t have to implement all of that weird stuff for your function.
Skeldon: Does that argue against APIs that have a funciton {}.apply ?
Gerrero: Mastropietro: undefined; Console: 4, 4
Diekema: Meh, there’s a way to do something like that.
Walthour: Maybe described in https://javascriptweblog.----escape_autolink_uri:a03ded6cd97ffffa8f7b4e1454f3eecc----.com/2011/01/18/javascripts-arguments-object-and-beyond/
Kulaga: I turned off javascript ONCE and now google think’s i don’t have it so it shows a super old version of their website
Belken: Does anyone know how to fix this?
Accosta: Okay, looks like the Spidermonkey version there just doesn’t conform. If you run that above code in current versions of V8 or Spidermonkey, probably, it says 4, 5
Boatman: Subli, sounds like a browser issue; you can tell by trying from another browser
Hardebeck: The SM on is from about 2008
Cassio: Yeah it’s fine in other browsers. thing is i can’t delete individual cookies
Mastropietro: Gerrero really needs an update
Hoffelmeyer: Jude, note spidermonkey comment below code pre in https://javascriptweblog.----escape_autolink_uri:a03ded6cd97ffffa8f7b4e1454f3eecc----.com/2011/01/18/javascripts-arguments-object-and-beyond/
Riel: Looks like an article from 2011
Fogerty: Nvm, found a way to do it
Gerrero: Jude: string ‘JavaScript-C 1.8.5 2011-03-31’
Brownfield: Okay, 2011 then, Firefox 4.
Mastropietro: Stavnes: I pushed a small update to ecmabot
Mastropietro: I’d like to know about his memory usage is _
Sambrook: SM is the engine used in firefox?
Jarzembowski: If x { etc etc } else { etc etc }
Sheild: Is this correct the else part in case x does not exit
Madalinski: Extreminador: “does not exit” – never terminates?
Madalinski: Well, it does exist. if you mean that it does not execute – of course, if “x” condition is truthy
Madalinski: Pre ES6, if you had function declaration there, it would hoist
Correy: Before that if i have this “x = procJogador targetSheet, “A”, 3, dJogador;”
Minucci: But procJogdor my return nothing
Madalinski: If “nothing” is null, undefined or empty string, then else part is indeed not executed
Madalinski: Or false, or any other falsy value
Lechel: Yehh else is never being executed indeed
Greenan: How can make to execute something else when x has nothing ?