!cxPCiPlsXnajakSrqd:matrix.org

Array languages

887 Members
General discussion about APL-like array languages. See #array:matrix.org for other rooms23 Servers

Load older messages


SenderMessageTime
25 Jan 2025
@oantolin:matrix.orgoantolin* In the appropriate font. I discovered I enjoyed BQN much more after I installed the BQN386 font. In the font I was using before all the 1-modifiers were too thin and small to see clearly and I kept screwing up. 😅19:40:26
@_discord_671689100331319316:t2bot.iobrian_e I recommend BQN. Feels modern because it has lexical scoping, great documentation, consistent function/namespace definitions (via blocks), is stable, and has custom inverses. Also imo a good primitive set. I think there's more reasons to recommend it, but those are some notable reasons i like a lot.
I'm only experienced with BQN and Dyalog APL, but i haven't felt the need to move from BQN.
22:42:26
@_discord_506589628418097152:t2bot.iosilas Dfns in Dyalog APL have lexical scoping too - it's more complex due to tradfns having dynamic scope… 22:45:39
@_discord_870115701279584326:t2bot.iodiscodoug It seems a bit of an odd question. Hard as it may seem it's all on you. If you have no interest, that's certainly fine. If you do, I suggest putting in the required energy to get something out of it. 22:57:53
@dzaima:matrix.orgdzaima (bridge dropped a bunch) 23:08:39
@_discord_506589628418097152:t2bot.iosilas yeah, there's nastiness with dfns/tradfn interacting about what scoping rules are followed. 23:28:10
@loke:dhsdevelopments.comlokeI'm not suggesting beginners start with Kap (because the documentation story for beginners could be a lot better), but the language was designed to deal with precisely these kinds of inconsistencies. There is no dynamic scope in the management, and the binding semantics follow Lisp.23:38:03
@loke:dhsdevelopments.comloke* I'm not suggesting beginners start with Kap (because the documentation story for beginners could be a lot better), but the language was designed to deal with precisely these kinds of inconsistencies. There is no dynamic scope in the language, and the binding semantics follow Lisp.23:38:18
@_discord_1024062732254843032:t2bot.ioen.de.lis wait does kap have separate function and variable namespaces? 23:40:25
@dzaima:matrix.orgdzaima yes 23:41:27
@_discord_1024062732254843032:t2bot.ioen.de.lis oh interesting! 23:41:49
@dzaima:matrix.orgdzaima actually, no, it's the same scope; has to be because variable/function reads don't have different syntax.. 23:43:48
@dzaima:matrix.orgdzaima it's a different characteer to assign functions, though, 23:44:20
@_discord_1162491071339712644:t2bot.iopolylokh_39446 yeah not a Lisp-2, or you could do stuff like this:
* (defun nest (list) (list list))
NEST
* (nest '(5))
((5))
23:47:53
@loke:dhsdevelopments.comlokeThey are actually separate (and also operator namespaces are different), but the parser will prefer the function definition if one is in scope.23:47:54
@loke:dhsdevelopments.comlokeSo basically, scoping is identical to CL, but it's hidden a bit in order provide APL-compatible calling conventions. The function isLocallyBound can be used to see the difference though.23:50:13
@loke:dhsdevelopments.comloke* So basically, scoping is identical to CL, but it's hidden a bit in order to provide APL-compatible calling conventions. The function isLocallyBound can be used to see the difference though.23:50:25
@_discord_506589628418097152:t2bot.iosilas is the hiding part of the reason behind having function application (⍞fn ) symbol? Or is that more to do with arrays of functions 23:53:30
@_discord_604614910030118912:t2bot.iorubenverg yeah quad quote is for lambdas 23:53:58
@loke:dhsdevelopments.comloke
In reply to @_discord_506589628418097152:t2bot.io
is the hiding part of the reason behind having function application (⍞fn ) symbol? Or is that more to do with arrays of functions
Not really. CL has APPLY and FUNCALL, which are essentially the same.
23:54:49
@loke:dhsdevelopments.comlokeIt's an artefact of having both separate namespaces and separate compilation before execution.23:56:06
@_discord_506589628418097152:t2bot.iosilas ok, suppose then my question is more why go with a lisp-2 style separation then? Understand wanting λ for ease with array of functions but don't quite see why you don't then allow reference with arguments to be the function call 23:58:25
@loke:dhsdevelopments.comlokeTo do away with APPLY you need to not only have a single namespace, but you also need a way to know if a variable is used in a function calling context or not. I considered early to use the BQN convention of using upper/lower case to indicate calling context, but I also wanted to be able to define new symbols, and then casing doesn't work.23:58:29
26 Jan 2025
@loke:dhsdevelopments.comloke
In reply to @_discord_506589628418097152:t2bot.io
ok, suppose then my question is more why go with a lisp-2 style separation then? Understand wanting λ for ease with array of functions but don't quite see why you don't then allow reference with arguments to be the function call
I think my previous message should explain that. But to clarify some more: in the expression a b c, you need to know if this is a call to a with stranded b c as arguments, or some other form. If you don't have explicit function call context, you wouldn't know what the above is until you run it.
00:00:44
@bear8642:matrix.orgsilasyes, asked on discord just as before this arrived00:01:08
@loke:dhsdevelopments.comlokeAnd that would prevent compiling an expression before it's executed. 00:01:10
@bear8642:matrix.orgsilas* yes, asked on discord just as before it arrived00:01:15
@bear8642:matrix.orgsilas* yes, asked on discord just before it arrived00:01:45
@bear8642:matrix.orgsilasindeed - so just another method to "clean" up. Was thinking there might've been some personal preference to use CL's function call model vs scheme's.00:04:50
@loke:dhsdevelopments.comlokeScheme works because it's clear from the syntax what is and what isn't a function call position. APL syntax doesn't have this. BQN gets away with it because it does indicate whenever a variable is used as a function call or a dereference (using case).00:08:12

Show newer messages


Back to Room ListRoom Version: 6