Daniel Kochmański on Nostr: npub19y8xk…vwxgj In both examples X is a lexical variable, while the scope where it ...
npub19y8xknr5twkrg2aeu6dyt9rhk5eg6punm4kl4q07pp0av8aa47esmvwxgj (npub19y8…wxgj)
In both examples X is a lexical variable, while the scope where it is declared as special is similar to using symbol-value. Essentially both examples are the same (except that in eg3 you assign 2 and in eg4 you assign 4 to the dynamic variable).
Using dlet (in reality - progv) shines when you have a private symbol (i.e created with gensym), then you can't refer to it by name, hence you can't declare it as special.
In both examples X is a lexical variable, while the scope where it is declared as special is similar to using symbol-value. Essentially both examples are the same (except that in eg3 you assign 2 and in eg4 you assign 4 to the dynamic variable).
Using dlet (in reality - progv) shines when you have a private symbol (i.e created with gensym), then you can't refer to it by name, hence you can't declare it as special.