When I set a breakpoint for a line, my tracing window closes and my cursor jumps back to the REPL with the prompt FN[347] where FN is indeed the function that I'm tracing and 347 is the line number where I've set a breakpoint. How can I prevent the tracing window from closing?
@Adám I just pressed Ctrl+Enter (which normally does run <TC>, e.g. when I enter an expression in the REPL and press Ctrl+Enter I start tracing it)... and nothing happened.
Yeah. Traditional APL implementations did just fine without such. Dyalog has namespaces, but they have two quirks, seen from a map/dict perspective: 1. They are pass by reference, rather than by value like all other APL arrays. 2. Keys are restricted to valid identifiers.
The traditional way is just having two arrays (or with the introduction of nested/heterogeneous arrays, a single nested array), one for the keys and one for the values.
okay here's the whole story: I'm not sure if I want to implement Variant, but if I do I'll probably opt for a special name (probably π) that's a dictionary of the passed options (so there is some normalization involved), which lead to considering having primitives for dicts
@Adám { "a": 1, "b": 2 } is ('a' 'b')(1 2), not ('a' 1)('b' 2) like I'd assumed was standard?
@RubenVerg ('a' 1)('b' 2) is a common way to specify name–value pairs, yes, but ('a' 'b')(1 2) is much faster to process and do lookups for. E.g. if you want to find all the keys that have values over 10, you do keys/⍨values>10 — try doing that with name–value pairs!
My father used to define where←⌿⍨ for this purpose, so you can do SQLy queries like name where age>18
turns out designing new primitives is much harder than I thought :) there's some things I somewhat often go "this could be a primitive" and then think about it and realize it'd be way too narrow-cased to be added