While I don’t have a direct answer, I know that my university had some courses dedicated to similar topics
www.students.cs.ubc.ca/~cs-311/…/goals.html
www.cs.ubc.ca/course-section/cpsc-411-201-2020w
www.cs.ubc.ca/~rxg/cpsc509-spring-2024/
The second one is described as
The goal of this course is to give students experience designing, implementing, and extending programming languages. Students will start from a machine language, the x86-64 CPU instruction set with Linux system calls (x64), and incrementally build a compiler for a subset of Racket to this machine language. In the process, students will practice building, extending, and maintaining a complex piece of software, and practice creating, enforcing, and exploiting abstractions formalized in programming languages.
The course assumes familiarity with basic functional programming in Racket, and some simple imperative programming in assembly.
Those links might give you something to search off of?
And what’s the purpose of developing more languages anyway?
At some level, I think it’s this:
ayyy@sh.itjust.works 1 day ago
This is an entire branch of computer science that people dedicate their lives to, called language design. You’re correct that we use software to translate a programming language into assembly language. That software is called a compiler.
As far as developing new languages, typically one starts by defining a “formal grammar”, typically in the .lex format. Since writing a whole compiler can be complicated and time consuming, most people just build off of the work of others and adapt an existing compiler such as “LLVM” to understand the grammar of their new language.
It sounds crazy to the uninitiated, but the best way to start learning about how to make computer languages is to learn about what a Turing tape machine is, and what it’s capable of. Then you will be able to understand what the difference between a “context-free” grammar and a “stateful” grammar.
ApathyTree@lemmy.dbzer0.com 1 day ago
Excellent thanks, I’ll look into that, and thank you for the information :)
You say “we” which hints that you have (some?) experience in the field, do you have any insight as to why one would want to create a new language rather than just helping to refine an existing one or something? Do they end up too bloated or do they function inherently differently or some other thing I haven’t thought of…?
ayyy@sh.itjust.works 1 day ago
I say “we” because I work in software which, past a basic level, involves endless arguing amongst colleagues about what the “best” language to use is for a particular project haha. Your question of why new languages is a really great one, with controversial answers haha.
What it boils down to is that every language is a set of opinions and compromises. Sometimes the assumptions that a language maker has just become less true over time. For example the language for making websites that was written in the 90s assumed that all you would need is a way to describe titles, paragraphs, columns, and some pictures. Websites do a lot more than that now, so people have come up with new languages for building websites.
A lot of it also comes down to people/politics. Since making and maintaining a language can be complex and expensive, it is frequently only taken on by large corporations. Those corporations are always doing their best to lock you into their ecosystem, and they use their language as a carrot. If you use our language and our services, everything will just work the way you want without hassle! By the way next year we are doubling the price of our services but whatcha gonna do about it, you already wrote a bunch of expensive code and hired a bunch of people that are only familiar with our language…pay up now!
ApathyTree@lemmy.dbzer0.com 1 day ago
That makes sense as to why Mozilla would be developing rust, then, thank you :)
One last (probably) follow-up question - is the payment to those companies for support purposes, or is it a license to even use the language? Like if you write your whatever in one language and then decide to swap…… umm… service providers I guess (maybe MSP situation?), do you need to re-write your entire whatever to no longer use it, or do you just no longer have support for issues?