Discuss Scratch

meowflash
Scratcher
500+ posts

The Secret To Making A Programming Language

I need secret to making a programming language!

More Stuff|My Bandcamp
My DeviantArt|Intro Voting For December 2015 August 10th 2016
Check out my Github, too!

Kumquats, this signature is inedible and poisonus.
Also try the code below in IBNIZ.
sxsaxAr+waxBr-*
JAVAProgramming
Scratcher
100+ posts

The Secret To Making A Programming Language

What do you mean, the “Secret” to making a programming language?

My Newest Project, Come Check It Out
Dots, On Scratch
Want to change the way we count? The Dozenal System.

“The story so far:
In the beginning the Universe was created.
This has made a lot of people very angry and been widely regarded as a bad move.”
― Douglas Adams, The Restaurant at the End of the Universe
turkey3
Scratcher
1000+ posts

The Secret To Making A Programming Language

Code, code, code

drmcw
Scratcher
1000+ posts

The Secret To Making A Programming Language

Use YACC

10 !
ScratchVaders or Galaga?
Maybe Eliza can help you decide?
meowflash
Scratcher
500+ posts

The Secret To Making A Programming Language

drmcw wrote:

Use YACC
I might use Scratch instead.

More Stuff|My Bandcamp
My DeviantArt|Intro Voting For December 2015 August 10th 2016
Check out my Github, too!

Kumquats, this signature is inedible and poisonus.
Also try the code below in IBNIZ.
sxsaxAr+waxBr-*
jgatcomb
Scratcher
90 posts

The Secret To Making A Programming Language

meowflash wrote:

I need secret to making a programming language!

If you are serious about doing this in Scratch, this is a huge undertaking.

Essentially, the process is:

1. Create a set of capabilities that your language will be able to do
2. Define a grammar that allows programmers to express their desired code
3. Parse users input into a form that is capable of being represented in terms of step 1
4. Execute

I have intentionally oversimplified the process to give you an overview but you could literally take years doing this and having spent a considerable amount of time with other languages - this seems like a very difficult task to do in Scratch.

Here are some light reading links to help you get started:

Compilers: Principles, Techniques, and Tools (also known as The Dragon Book)
Lexical Analysis
Abstract Syntax Tree

Cheers,
Joshua
drmcw
Scratcher
1000+ posts

The Secret To Making A Programming Language

jgatcomb wrote:

meowflash wrote:

I need secret to making a programming language!

If you are serious about doing this in Scratch

No-one could be serious about doing it in Scratch

10 !
ScratchVaders or Galaga?
Maybe Eliza can help you decide?
jgatcomb
Scratcher
90 posts

The Secret To Making A Programming Language

drmcw wrote:

No-one could be serious about doing it in Scratch

Having been programming for 20 years with many different languages, there are two things about Scratch that stand out:

1. It lacks so many features of other languages I find it hard to understand how anyone accomplishes anything
2. People are able to accomplish so many amazing programs

Assume someone wasn't in their right mind and they did want to create a programming language within Scratch - parsing/lexing would nearly impossible. No support for sub-string, index, regular expressions, etc.

I have a How To Studio. Its intent is not to be complete programs but to specifically show how to do something (I will probably post how to generate the powerset of a list next).

For the briefest of moments I considered trying to do a basic regular expression engine and then sanity once again returned.

Cheers,
Joshua
dowcwow
Scratcher
67 posts

The Secret To Making A Programming Language

meowflash wrote:

I need secret to making a programming language!
How did you make those fake ad things

Powered by DjangoBB