Hacker News new | ask | show | jobs
by m463 2552 days ago
I watched a fascinating presentation and when I saw the speaker typing (lambda ...) and having it change to (λ ...) and not having to deal with parens.. I was jealous.

Does emacs do this?

EDIT: the presentation:

William Byrd on "The Most Beautiful Program Ever Written"

https://www.youtube.com/watch?v=OyfBQmvr2Hc

3 comments

Yes, M-x prettify-symbols-mode, it's very cool. For parens, there's the built-in electric-pair-mode, paredit, smartparens, and lispy.
Some languages understand λ directly (and in all lisps that support unicode, you can explicitly alias it) - I've occasionally mapped AltGr+L to λ, when playing with those. It's really nice.

APL perhaps goes a little far, but I'd like to see more standardized symbols in programming languages. Imagine how nice it would be to succinctly use things like the actual outer-product operator ⊗...

> APL perhaps goes a little far

When I learned APL long ago in a languages course, it was on a dedicated APL setup with an APL keyboard.

In that context, it was a "how SHOULD things be" sort of design decision. I know I started off quickly thinking in terms of math and the language, not composing symbols.

Of course, APL keyboards have gone the way of the dodo and so the language has a higher barrier to entry.