-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Atom/quick ideas based on a Jelly corpus #69
Comments
I considered a hacky solution for mapping structures back when I added prefixes and suffixes. It would be |
In that sense, a quick with syntax |
@GolfingSuccess Can you share some examples demonstrating how that would be useful? I'm intrigued. |
@lynn My newest example as of writing this. |
I've implemented all of the constant nilads. aeeadda |
|
|
These atoms along with several more nilads have been added. Here is an updated list with implemented tokens at the bottom. |
Putting this here, so it doesn't get lost and forgotten in the Jelly chatroom history:
I used SE Data Explorer to gather a corpus of Jelly source code lines, on which I performed some frequency analysis, resulting in
These lists gave me an idea of which common phrases deserve a 2-byte (or even 1-byte) alias. I compiled a big list of ideas for new atoms and quicks inspired by them. Feel free to comment on their merit or implementation here.
Some thoughts that came out of this in the chatroom:
µ€
, because it’s ridiculously common.Ѐ
andÐf
and some others should have really been one byte, but it isn’t too late to make aliases for them.€
is by far the most common character in Jelly code, which is maybe surprising given that Jelly has automatic vectorization. We might want a 1-byte alias forS€
, which comes up very often. We might also want to make a bunch of quicks that are short for “get all (blah) and map over them”, e.g.□ÐP
could be short forŒP□€
.ẏ
andŜ
, making room for a new monadic atomŜ
while retaining backwards compatibility.The text was updated successfully, but these errors were encountered: