
APL\iv: an APL interpreter and stream processor written in Go - chrispsn
https://github.com/ktye/iv
======
nemo1618
Fun fact: All three of Go's creators have written APL interpreters, and Go's
"iota" keyword is modeled after the corresponding APL operator.

~~~
kasbah
Rob Pike also implemented an APL-like big number calculator in Go more
recently: [https://github.com/robpike/ivy](https://github.com/robpike/ivy)

>The author has never used APL. It's a chicken and egg problem. (...) All
testing has been done with tryapl.org.

There are also a few free software implementations of APL most notably GNU
APL. I have been sticking to that while learning APL.
[https://www.gnu.org/software/apl/](https://www.gnu.org/software/apl/)

~~~
threwawasy1228
I've personally found GNU APL to be a bit flimsy, and not some of the design
choices they made in it to be a bit odd. It also deviates from the ISO
standard, if that matters to you.

Dyalog is the only implementation that is robust and production ready that is
still actively maintained. I would suggest learning with something other than
the GNU implementation.

~~~
fusiongyro
Dyalog also deviates from the ISO standard, adding things from J like hooks
and forks. IIRC, GNU APL's deviations are to bring it closer to IBM APL2, but
it's been a while since I cared about any of this.

------
jim-jim-jim
A bit tangential, but what do people here use to input APL characters in
macOS?

I've been using Dyalog's GUI, but I'd much rather be using free software from
the usual terminal. It'd be nice if there were just a global input method like
the ones they have for human languages.

~~~
i_don_t_know
Follow the instructions at [https://www.dyalog.com/apl-font-
keyboard.htm](https://www.dyalog.com/apl-font-keyboard.htm)

Then add another input method for APL as you would for switching between
English, German, French, etc keyboard layouts.

------
kwhitefoot
Slightly off topic: what might this or any other APL interpreter be used for
in what one might call mainstream business or technical applications?

------
gaius
_Disclaimer

The author has never used APL_

I’d like to know more about the underlying motivation! APL is a fascinating
language but I’m not sure how you’d implement it efficiently in a language
like Go - you would need intrinsics to get at the vector instructions no?

~~~
jerf
Go assembler can get to vector instructions, for instance as used by
Cloudflare to implement crypto speedups: [https://blog.cloudflare.com/go-
crypto-bridging-the-performan...](https://blog.cloudflare.com/go-crypto-
bridging-the-performance-gap/)

~~~
grumpydba
Indeed but without intrinsics, functions using those vector instructions
cannot be inlined, and the go calling convention's overhead is still big.

