|
Hi, correct. To explain why this is so, consider this: {1+2} 3 {1+⍵} SYNTAX ERROR {1+⍵} 5 6 Therefore in F0←{1+2} GNU APL first reduces {1+2} to 3 and then assigns 3 to F0, making F0 a variable because a values is being assigned to a name. This is normal APL and holds for all niladic functions and not only for niladic lambdas. In contrast, in F1←{1+⍵} {1+⍵} cannot be reduced (as opposed to {1+⍵} 5 which can), so it is shifted onto the evaluation stack, then ← is shifted (still not being able to be reduced), and finally F1 is shifted. At this point the stack contains the valid phrase F1←{1+⍵}, which can be reduced and causes F1 to become a monadic function bound to the name F1. /// Jürgen On 10/25/2016 07:01 PM, Christian
Robert wrote:
DISPLAYhand←{,(⍪hand),' '} |
- [Bug-apl] dynamic function not referencing global? alexweiner
- Re: [Bug-apl] dynamic function not referencing glob... Christian Robert
- Re: [Bug-apl] dynamic function not referencing ... Juergen Sauermann
- Re: [Bug-apl] dynamic function not referenc... Ala'a Mohammad
- Re: [Bug-apl] dynamic function not refe... Juergen Sauermann
- Re: [Bug-apl] dynamic function not... Ala'a Mohammad
- Re: [Bug-apl] dynamic function... Juergen Sauermann
- Re: [Bug-apl] dynamic function not referenc... Christian Robert
- Re: [Bug-apl] dynamic function not refe... Juergen Sauermann
- Re: [Bug-apl] dynamic function not... Christian Robert
- Re: [Bug-apl] dynamic function not referencing glob... Christian Robert
