Content deleted Content added
Assessment: Computing: software=y, software-importance=Mid, importance=Low (assisted) |
Example and text don't match |
||
Line 813:
Hi, these two seemed to me as typos but I'm not sure, and this is my first attempt to contribute to wp.. In '''Delegates (C#, D)''' section, the sentence "For example, the above code will not work correctly, because the variable a is on the stack, and after returning from test(),..." it is not clear to which function test() refers, test1(), test2() or both? And in the last sentence "The same is true for inner's class methods that..." should it be "inner" instead of "inner's class methods" or am I missing something? --[[User:S.POROY|S.POROY]] ([[User talk:S.POROY|talk]]) 19:45, 15 May 2017 (UTC)
== Example and text don't match ==
I was reading this article and found this mismatch in section "Lexical environment". There is no <code>foo</code> function nor <code>f</code> or <code>g</code> variables. I think the text is referring to the example in section "Anonymous functions". Example and text follows:
<source lang="ecmascript">
'use strict'
function makeFunc() {
const name = "Closure";
function displayName() {
console.log(name);
}
return displayName;
};
const runFunc = makeFunc();
runFunc(); //Closure
</source>
Note how function<code>foo</code> and the closures referred to by variables <code>f</code> and <code>g</code> all use the same relative memory ___location signified by local variable <code>x</code>.
[[User:Bjacquet|Bjacquet]] ([[User talk:Bjacquet|talk]]) 11:59, 19 March 2018 (UTC)
|