Discuss Scratch
- Redstone1080
-
1000+ posts
Custom Programming Languages
Discuss programming languages you're:
a) in the process of making, so you can't make a topic yet, or
b) don't want to make a topic about :P
a) in the process of making, so you can't make a topic yet, or
b) don't want to make a topic about :P
Last edited by Redstone1080 (Oct. 9, 2023 12:12:15)
- Redstone1080
-
1000+ posts
Custom Programming Languages
I remember making a terrible lang once called Efflo. Basically it worked like Python bytecode but even more verbose :P
I think it's on GitHub somewhere
I think it's on GitHub somewhere
- __Falcon-Games__
-
1000+ posts
Custom Programming Languages
Did you make this topic because of Sandwich?
- __Falcon-Games__
-
1000+ posts
Custom Programming Languages
That is about writing a programming language, this is about discussion of programming languages we are making. Duplicate?
https://scratch-mit-edu.ezproxyberklee.flo.org/discuss/topic/612872
- TheSecondGilbert
-
100+ posts
Custom Programming Languages
I had a language called Touché, a scratchblocks-like language that compiles into a Scratch project à la GCC, and is also made to be extendible so that it also works with mods and other block-based proglangs as well.
It's been put on the back burner since it's in dev hell for being too ambitious. The structure needs to be revamped since I don't know how to part compilers correctly (or at least in a flexible manner). I've also been struggling to find a suitable parser library (to the point that I had to briefly switch my language from Python to JavaScript) until I've decided to make my own (albeit inefficient) parser. Those and the unfortunate event of my laptop going into a coma recently, ceasing development of all my projects.
Moral of the story: If you want to dream big, at least know in detail what you're dreaming of.
It's been put on the back burner since it's in dev hell for being too ambitious. The structure needs to be revamped since I don't know how to part compilers correctly (or at least in a flexible manner). I've also been struggling to find a suitable parser library (to the point that I had to briefly switch my language from Python to JavaScript) until I've decided to make my own (albeit inefficient) parser. Those and the unfortunate event of my laptop going into a coma recently, ceasing development of all my projects.
Moral of the story: If you want to dream big, at least know in detail what you're dreaming of.
- __Falcon-Games__
-
1000+ posts
Custom Programming Languages
Oh wow, I also created a Scratch-like language and it was much more simpler and easier for me. I had a language called Touché, a scratchblocks-like language that compiles into a Scratch project à la GCC, and is also made to be extendible so that it also works with mods and other block-based proglangs as well.
It's been put on the back burner since it's in dev hell for being too ambitious. The structure needs to be revamped since I don't know how to part compilers correctly (or at least in a flexible manner). I've also been struggling to find a suitable parser library (to the point that I had to briefly switch my language from Python to JavaScript) until I've decided to make my own (albeit inefficient) parser. Those and the unfortunate event of my laptop going into a coma recently, ceasing development of all my projects.
Moral of the story: If you want to dream big, at least know in detail what you're dreaming of.
- Steve0Greatness
-
1000+ posts
Custom Programming Languages
I “recently” made a implementation of Bluefun(one of those weird Esoteric programing languages that doesn't serve a purpose). I say “recently”(in quotes) because I actually made it 2 months ago. It's repo can be found at @Steve0Greatness@github.com/Go-Bluefun.
It also added some extra features onto that language to make it less of a nightmare to write in… it's still not fun…
It also added some extra features onto that language to make it less of a nightmare to write in… it's still not fun…
Last edited by Steve0Greatness (Oct. 9, 2023 20:02:05)
- davidtheplatform
-
500+ posts
Custom Programming Languages
I'm thinking about making a sort of cross between python and java. I don't really know how to make a compiler though
- sf97ahgf
-
100+ posts
Custom Programming Languages
AFAIK LLVM is great if you want to write languages without the hassle of creating compilers for multiple complicated instruction sets.
- davidtheplatform
-
500+ posts
Custom Programming Languages
AFAIK LLVM is great if you want to write languages without the hassle of creating compilers for multiple complicated instruction sets.Yeah that's what I'm going to use
- ajskateboarder
-
1000+ posts
Custom Programming Languages
In a literal sense, there's I'm thinking about making a sort of cross between python and java. I don't really know how to make a compiler thoughJython, which lets Python interop with Java and vice versa. I think it's stuck on Python 2 support though

- davidtheplatform
-
500+ posts
Custom Programming Languages
That's… interestingIn a literal sense, there's I'm thinking about making a sort of cross between python and java. I don't really know how to make a compiler thoughJython, which lets Python interop with Java and vice versa. I think it's stuck on Python 2 support though
The goal is more for it to have python-like syntax but also a sane OOP system, and be compiled. Static typing would be optional, but the compiler would try to figure out the actual type of something if you don't specify it.
Something that really annoys me with most OOP languages is that there isn't a native way to have a variable which can only be changed inside the class. You can emulate this by making the variable private and using a getter, but that feels unnecessary.
- ajskateboarder
-
1000+ posts
Custom Programming Languages
Interesting language idea, but inferring types might cause compilation times to go completely beyond human comprehensionThat's… interestingIn a literal sense, there's I'm thinking about making a sort of cross between python and java. I don't really know how to make a compiler thoughJython, which lets Python interop with Java and vice versa. I think it's stuck on Python 2 support though
The goal is more for it to have python-like syntax but also a sane OOP system, and be compiled. Static typing would be optional, but the compiler would try to figure out the actual type of something if you don't specify it.
Something that really annoys me with most OOP languages is that there isn't a native way to have a variable which can only be changed inside the class. You can emulate this by making the variable private and using a getter, but that feels unnecessary.
Also I totally agree with you, you shouldn't have to write getter and setter boilerplate to do something as simple as change a variable
- davidtheplatform
-
500+ posts
Custom Programming Languages
The compiler would just check the places where it's assigned, and if they're all the same type the variable is static, otherwise it's dynamic. You already have to do this to detect type mismatches so it won't add very much compilation time.Interesting language idea, but inferring types might cause compilation times to go completely beyond human comprehensionThat's… interestingIn a literal sense, there's I'm thinking about making a sort of cross between python and java. I don't really know how to make a compiler thoughJython, which lets Python interop with Java and vice versa. I think it's stuck on Python 2 support though
The goal is more for it to have python-like syntax but also a sane OOP system, and be compiled. Static typing would be optional, but the compiler would try to figure out the actual type of something if you don't specify it.
Something that really annoys me with most OOP languages is that there isn't a native way to have a variable which can only be changed inside the class. You can emulate this by making the variable private and using a getter, but that feels unnecessary.
Also I totally agree with you, you shouldn't have to write getter and setter boilerplate to do something as simple as change a variable
- ninjaMAR
-
1000+ posts
Custom Programming Languages
I made this really bad language similar to lisp
https://github.com/ninjamar/nm
https://github.com/ninjamar/nm
- __Falcon-Games__
-
1000+ posts
Custom Programming Languages
So to create an object in Sandwich you don't need to create classes first, here's how you do it.
And for classes.
import Console
fun main() {
obj = Standard.Object(a=1, b=2, c=3)
Console.out(obj.a, obj.b, obj.c)
}
1
2
3
And for classes.
import Console
class Fruit(type) {
fun summary(type) {
Console.out("I am a fruit of type " ++ type)
}
type = type
summary = expand(summary)
}
apple = Fruit("apple")
Console.out(apple.type)
Console.out(apple.summary())
apple
I am a fruit of type apple
- rdococ
-
1000+ posts
Custom Programming Languages
Interesting… what does the ‘summary = expand(summary)’ line do? -snip-
- ajskateboarder
-
1000+ posts
Custom Programming Languages
Reminds me a lot of JavaScript objects - very powerful feature - but not a very huge fan of the Standard.Object declaration. Seems a bit too verbose compared to using braces, yes? So to create an object in Sandwich you don't need to create classes first, here's how you do it.import Console
fun main() {
obj = Standard.Object(a=1, b=2, c=3)
Console.out(obj.a, obj.b, obj.c)
}1
2
3
YeahInteresting… what does the ‘summary = expand(summary)’ line do? -snip-
- TheSecondGilbert
-
100+ posts
Custom Programming Languages
Could this be a bit easier? (for example, calling `object` instead of `Standard.Object`) So to create an object in Sandwich you don't need to create classes first, here's how you do it.import Console
fun main() {
obj = Standard.Object(a=1, b=2, c=3)
Console.out(obj.a, obj.b, obj.c)
}1
2
3
And for classes.import Console
class Fruit(type) {
fun summary(type) {
Console.out("I am a fruit of type " ++ type)
}
type = type
summary = expand(summary)
}
apple = Fruit("apple")
Console.out(apple.type)
Console.out(apple.summary())apple
I am a fruit of type apple