Vote count:
0
In Harmony, there is a let keyword that allows for declaration of variables that are scoped to the nearest block. For example
function foo() {
if (true){
let a = 100;
}
return a
}
will result in an error since a is only defined inside the if block.
I know I can use del to achieve the same thing, but that that is manual instead of automatic like the let keyword
asked 38 secs ago
Aucun commentaire:
Enregistrer un commentaire