Follow

I've been trying to come up with a new unique list comprehension syntax for my toy language. I'm aiming mostly for readability without adding too many special characters/keywords. Any ideas?

@kyle what does the rest of your language look like?

[fn] each [element] of [list] is pretty readable for the basic case.

@whtrbt Here's the project, the readme should give you the gist git.kyleperik.com/kyle/judo/

It's a logical/functional language

@kyle ah yes, I see my suggestion is way too keywordy!

@whtrbt I do like that, and it's not to far off from python. I'd like to avoid the special keywords if possible... using something that can be built in to the language.

But to contrast, I think javascript's built in list methods are clunky. `.filter(...).map(...)` make for long lines or oddly placed line breaks.

I think it's a tricky balance but I'm really curious to what could be.

Sign in to participate in the conversation
Merveilles

Revel in the marvels of the universe. We are a collective of forward-thinking individuals who strive to better ourselves and our surroundings through constant creation. We express ourselves through music, art, games, and writing. We also put great value in play. A warm welcome to any like-minded people who feel these ideals resonate with them. Check out our Patreon to see our donations.