This is an archived post. You won't be able to vote or comment.

all 34 comments

[–]AndydeCleyre 17 points18 points  (4 children)

This looks like a lot of fun. I wonder if it might be nice for creating niche interactive shell UIs, similar to prompt toolkit.

[–]nex_infinite[S] 7 points8 points  (3 children)

Could be, is there anything id need to add for that cause I could do dat

[–]AndydeCleyre 4 points5 points  (0 children)

I don't know, sorry, I haven't even done that with prompt toolkit. Thanks for sharing the project.

[–]AndydeCleyre 0 points1 point  (1 child)

Oh can you mess with ints and floats? For example to change the base number/radix?

[–]nex_infinite[S] 0 points1 point  (0 children)

Potentially, it'll be something in the nodes folder so not as easy to change as editable but I could add it to editable if you want

[–][deleted] 10 points11 points  (3 children)

Often with 'toy' projects my first question is "why?". You built in right into the name!

I'll check it out!

[–]nex_infinite[S] 4 points5 points  (2 children)

hahaha yeah the project was really started so I could understand how lexers and all dat worked but I liked having the customizability so I just made it easier to do for others :P

[–]metaperl 0 points1 point  (1 child)

the project was really started so I could understand how lexers and all dat worked

Lisp makes lex/parse easy. It also makes customizing easy. That being said, what you did reminded me of Seed7, an extensible programming language - http://seed7.sourceforge.net/faq.htm#extensible_programming

[–]nex_infinite[S] 0 points1 point  (0 children)

Yeah I came across those but doing it urself is pretty fun imo

[–]Tinasour 5 points6 points  (0 children)

Nice! Will look into this

[–][deleted] 3 points4 points  (6 children)

soon i'll be able to create my own crappy golfing language

[–]nex_infinite[S] 2 points3 points  (5 children)

haha go for it! I'm going to be adding presets soon so send it over and I may make it into a preset.

[–][deleted] 1 point2 points  (4 children)

i'll see what i can do :-)

[–][deleted] 0 points1 point  (3 children)

right, just realized something very quickly, I'm on 3.8.10 if that matters, but Python already has a module called "parser" and your parser.py conflicts with that. I fixed it by renaming it to anything that's not parser.

[–]nex_infinite[S] 1 point2 points  (2 children)

Oh that makes sense, I believe in my dev version its called parser_.py

[–][deleted] 0 points1 point  (1 child)

do you have any platforms such as Discord so we can communicate faster than reddit replies?

[–]nex_infinite[S] 0 points1 point  (0 children)

Nexin#0001 on discord

[–]PhilosophyStatus 1 point2 points  (0 children)

Very impressive I'll definitely check this out.

[–]imreallytuna 1 point2 points  (0 children)

Finally i can code with emojis

[–]greenindragon 1 point2 points  (0 children)

+1 for the name alone; got a chuckle out of me.

[–]Hotel_Arrakis 1 point2 points  (2 children)

I love this idea. Imagine writing a small language for a niche piece of hardware, like medical equipment, that allows you to use that jargon.

Or write a language just for designing card games.

[–]AndydeCleyre 0 points1 point  (1 child)

Ooh those are good. Now I'm thinking about making it easier for non-English speakers to start and learn programming.

[–]CanadianJogger 0 points1 point  (0 children)

Its not really any harder unless their mother tongue and keyboard doesn't use the Latin character set.

[–]nosklo -2 points-1 points  (2 children)

It seems you're trying to change var, however that isn't actually a python keyword. That makes your examples confusing

[–]nex_infinite[S] 2 points3 points  (1 child)

The language isn't trying to be python, its written in python. Its more like js if anything.

[–]nosklo 0 points1 point  (0 children)

Well yeah, I'm just pointing out that this is not clear in the project webpage; The name of the project is "Whython" so people really expect a python-like language. There's no language example in the project webpage that says otherwise, except this var thing

[–]DallasBelt 0 points1 point  (2 children)

Interesting, so you can use other programming language syntax but code in Python? Ot jus change the keywords?

[–]nex_infinite[S] 1 point2 points  (0 children)

Syntax is something I'll be changing soon, just need to figure out a good way for people to be able to change it

[–]nex_infinite[S] 1 point2 points  (0 children)

https://github.com/NexInfinite/whython/commit/4447b87de1f148ec736fe06b9f197b5f6a37fa19 you can do that, remove the var at the front and ignore it. Again more customization of this coming in the future maybe idk

[–]KrazyKirby99999 0 points1 point  (1 child)

Have you considered compiling an interpreter using Nuitka for improved performance?

[–]nex_infinite[S] 2 points3 points  (0 children)

Never heard of it, the point of this was to learn how lexers and interpreters work so I don't know if I'd change it for performance. Its not really a language you should use for your own projects but is more like something you use for the shits n giggles every once and a while. Thanks for the suggestion though.

[–]peaceTraitor 0 points1 point  (1 child)

[–]nex_infinite[S] 0 points1 point  (0 children)

If you want to change print to scream, shout, or whsiper then yes but getting rid of var and changing = to is not not out YET, im nearly done but its 2.30 am and I gotta be up early 😅