The fact that its grammar cannot be expressed as EBNF (like Ada) does not mean that it's not precise and consistent.
I wasn't objecting to the fact that it can't be expressed in EBNF, but the reason you gave -- that so much of the language can be redefined at will. Suddenly you have to look in dozens of different places to verify what the most basic features of the language are.
Overall, the grammar is much more consistent than most other languages, if only because it's so small. As I indicated elsewhere in this discussion, scanner and parser together represent some 1500 lines of C++ code, and a syntax file that is currently 62 lines long. A complete and precise description of the core language in plain english takes about 50 pages. Compare that to the 700 pages for the C++ standard, and tell me which one is easier to teach?
Lisp has a tiny grammar and a small standard, and that leaves us buggering about with a visual confusion of brackets and parentheses. The point of high-level languages is to impose a more human-freindly logic over the CPU's instruction set.
What I need is not so much a consistent grammar as a consistent behaviour -- the expressive logic of the language must be consistent, and if the basic behaviour of the language is overridable at will, then it is not consistent from day to day, or from job to job.
Metaprogramming is a powerful paradigm, because it allows you to take a general purpose language and make out of it a language optimised to the particular task you are trying to achieve. But Tao3D (as you present it) is a language with a very narrow, dedicated purpose: it's 3D-Powerpoint-on-steroids. Why on Earth is anyone going to want to override operator precedence for making a presentation? And once they've done it, are they going to remember they've done it? Are they going to remember the next time?
If you want to look at your input in a Lisp-ish syntax, you can, there's an option in the compiler to dump the parse tree in such a format.
That's technically possible with any language. But if I need that to debug my code, then the published spec is inadequate.
Anyway, I've got a more specific critique here. I'd like to see your response to that.
Maybe you never had to work in a large project where the project most productive guy did no care about indentation at all. Whitespace has a semantics for our brain, so we might as well make that consistent with the code. It reduces syntactic noise, in concept programming jargon.
I like to let my IDE correct my indentation in such situations. I know what's coming next... "ah, but the diffs..." but that's a problem with the diffs, not the code. If the diff algorithm treated non-semantic whitespace non-semantically (ie multiple whitespace treated as single whitespace, as an HTML parser does) then it wouldn't be a problem, and the diffs would show up the actual material differences (the changes in start-block and end-block markers), and my IDE could set the indentation depths to my preferences, and adjust them based on screen and font sizes (so that I can debug on a netbook what a colleague wrote on a 24" monitor.
The problem with Python is that it's designed to look like other languages.
The problem with BASIC is that it's crap.
Everybody who tries to make a new language these days makes a very similar series of mistakes, under an understandable rationale of either "well, this is the gateway, so it's got to prepare them for 'real' languages" or "the language will never take off if existing programmers find it too alien". When we get to things like GameMaker, you end up with a claim of "programming without programming", but what we find under the hood is a basic C++/Java-lite OO language with crucial programming ideas rechristened with "friendly" names that only serve to further obscure the logic from the programmer.
The only change needed is the addition of labels instead of line numbers as references, and then we could type GOTO HELL, which would make BASIC look self-aware....
I consider the loss of the Challenger criminal negligence, even though no-one was charged. That something so trivial as a silicone O-ring was allowed to kill 7 people and destroy millions of pounds worth of government property was utterly ludicrous. The vehicle had operating temperature specs, and that should have been based on the least tolerant component. Someone must have fiddled the books somewhere along the line.
You completely missed the point, there. Titanic served a useful purpose, it transported people across the sea.
Actually, you missed an important point too. The Titanic's design was a combination of "appeal as much as possible to rich people" and "generate as much profit as possible". The Titanic sank for business reasons, during the great and noble quest for profit. People didn't stop using tried and tested designs when the Titanic sank, they just didn't build another Titanic. Ariane rockets etc have proven pretty trustworthy. It's a fair comparison.
But we have other designs already that are already successful at getting human beings into space and staying there. Space tourism is trying to reduce spaceflight costs, and there is an argument that pricetags vs personal safety don't make for good calculations.
You don't get it. He's not trying to tell you that presentations everywhere are supposed to look like what he demos on the screen, and that everybody must change, he's showing you that there is a great language and environment for making interactive presentations in 3D.
But in his own demos, he trips into the "too much potential results in too much noise" trap -- he adds letter codes to the base proteins in the DNA helix, in default black, then forgets to change the colour before applying the space theme, at which point they're hidden and promptly forgotten about.
Besides, that whole demo has no persistent representation of the structure, except one that is hacked in by spiking the random number generator with a seed so that when the 3D objects are generated from the ground up on every redraw, they look like the same thing. This isn't user-friendly logic.
Let me disappoint then. I don't think you can even write a valid EBNF for XL, it's too dynamic for that. Let me explain why.
[....]
Again, it's "yuck" for formal grammar nazis. But again, I don't care, because it just works.
Except when it doesn't just work and you have to debug, because then what you describe as "dynamic" starts to feel like "unpredictable" and it takes far longer to work through than it should. I've only looked at a very small example, but I cannot imagine myself ever trying to teach how to program in this language. How do you teach someone to think like something with very little internal logic or consistency?
Punters use them to propel their boats. Actually, 12 foot poles are more common, and that's another variation of the phrase. I suspect the phrase refers to punters using their poles to fend off other boats....
Consider it a "video demonstration" then, and consider that it demonstrates some curious weaknesses in the language. (I watched the DNA strand video.)
I don't like subroutine names that include something that looks like a parameter, so things like rotatex and rotatey set me on edge a bit. It gets worse when this is inconsistent, and you see a subroutine called vertical_align for vertical alignment, where the seeming parameter (vertical) is now before the generic (align), and separated by an underscore instead of run together. Not only is this an internal inconsistency, but it's inconsistent with English, as "align" is a verb, and we would put in an adverb "vertically" after the verb normally. And then it gets worse again, as the command for horizontal alignment is... "align".
The grammatical inconsistency continues with other commands/subroutines taking on names with no verb component at all (eg the command color, with no verb or assignment operator.
I'm really not happy with the way pattern matching is used as overloading:
dna_base_color 0 -> color "red"
dna_base_color 1 -> color "blue"...
rather than a single structure with explicit choices, eg
dna_base_color:
0 -> color "red"
| 1 -> color "blue"...
...because you can get yourself in a mess if you split it up into different parts of the code and accidentally overwrite stuff.
I'm completely baffled why the whole demo recreates the shapes for every single redraw frame rather than keeping them as persistent objects (which necessitates adding a random seed in order to fake them being persistent by pulling up the same colours each time.
(The demo also demonstrates the whole potential of doing too much and drowning yourself in flash -- notice how DNA letter codes are added, then promptly disappear in a black-on-black clash and are forgotten about.)
But the worst part is the way these rotations and coloring statements create a hidden state that affects things below in an opaque manner... and I'm not even sure it might not effect stuff above it.
There's a remarkable similarity between everything I've just said and the criticisms I've read of processing/processing.js (eg Bret Victor's opinions on Khan Academy's coding tutorials), so I'm guessing this was very heavily inspired by Processing's 2D canvasses....
Nah, I have found that English doesn't really suit my needs, so over time I've have extended it with additional info-enhancefic-features that allow me to wrt +>concs.ly n x that m.mess.g is +>qwk.
Common Lisp macros allow you to create complex language extensions which are not library functions. They perform as though they are built in. Before anyone writes a "new" language they should at least survey the already existing solutions.
Yes, but unfortunately it still leaves you programming in Common Lisp. Lisp was not designed for humans -- it was designed to be easy for the computer to parse. Worse, ukasiewicz's prefix notation may be known as "Polish notation" now, but he called it "parenthesis-free notation" when he invented it (and that was his whole purpose in inventing it), and yet the guys who invented Lisp used prefix with mandatory parenthesis. Lisp was an interesting idea at the time, and dealt with the constraints of the time, but now it's of more use as a study of why the distinction between a "high-level" and "low-level" language isn't exactly clear cut....
Also, requiring "locally" seems to imply that it has one of the worst "features/bugs" of JavaScript design for default globals? Or maybe I did not understand "locally".
The 'locally' function does not concern variables, but graphic state. It's a way to say "I don't want this rotation to escape this block". In OpenGL terminology, you can think of it as a PushMatrix/PopMatrix pair (and same for other attributes).
So does this mean that Tao3D is call-by-value by default, and this explicitly breaks it to (effectively) call-by-value, rather than leaving the programmer to hack around with statics or constants and individual copies of arguments?
I like the clean looking syntax without semicolons at the end of lines. I'm assuming it uses indentation after a comma to define code blocks?
That's all fair comment. The power of the Axis forces was, after all, rooted in the unity of feeling the various fascist groups instilled in their populations.
But it's a million miles from the modern myth of France just waving a white flag.
Breaking news: Amelia Earhart has been discovered alive and well on a Pacific island. Doctors in the TIGHAR-sponsored search party say the avatrix is doing well. However, due to her advanced years and resultant dementia, Earhart is unable to identify herself. Ric Gillespie, executive director of TIGHAR, denies that the woman is in fact Mary Montgomery, 74, of New Springs, Idaho, who was reported missing last week after failing to turn up for dinner on board the prestigious cruise ship Pacific Star. Speaking to reporters, Gillespie said "clearly Amelia managed to rig up the components of her radio set into a receiver and heard the story about the missing woman, and due to her advanced cognitive decline, began to associate herself with the news that she heard. Unfortunately, she appears to have lost this radio between hearing the news and our arrival."
Come on... the Turin Shroud is a unique and genuinely mystifying artefact (and I say that as someone who doesn't believe in any god). This is... a chunk of metal. with some holes in it.
It can't be water tank -- it's got holes in it, so the water would run out. That only leaves the Earhart theory. Nothing else could be at all possible, no sirree...
The bones found might have been from Amelia Earhart's body. When the measurements of the bones were looked at in 1998 was it noticed that they could have been Earhart's. Thankfully, the internet being what it is, everyone knows her body was found, and that this is an absolute, unquestionable fact.
The fact that its grammar cannot be expressed as EBNF (like Ada) does not mean that it's not precise and consistent.
I wasn't objecting to the fact that it can't be expressed in EBNF, but the reason you gave -- that so much of the language can be redefined at will. Suddenly you have to look in dozens of different places to verify what the most basic features of the language are.
Overall, the grammar is much more consistent than most other languages, if only because it's so small. As I indicated elsewhere in this discussion, scanner and parser together represent some 1500 lines of C++ code, and a syntax file that is currently 62 lines long. A complete and precise description of the core language in plain english takes about 50 pages. Compare that to the 700 pages for the C++ standard, and tell me which one is easier to teach?
Lisp has a tiny grammar and a small standard, and that leaves us buggering about with a visual confusion of brackets and parentheses. The point of high-level languages is to impose a more human-freindly logic over the CPU's instruction set.
What I need is not so much a consistent grammar as a consistent behaviour -- the expressive logic of the language must be consistent, and if the basic behaviour of the language is overridable at will, then it is not consistent from day to day, or from job to job.
Metaprogramming is a powerful paradigm, because it allows you to take a general purpose language and make out of it a language optimised to the particular task you are trying to achieve. But Tao3D (as you present it) is a language with a very narrow, dedicated purpose: it's 3D-Powerpoint-on-steroids. Why on Earth is anyone going to want to override operator precedence for making a presentation? And once they've done it, are they going to remember they've done it? Are they going to remember the next time?
If you want to look at your input in a Lisp-ish syntax, you can, there's an option in the compiler to dump the parse tree in such a format.
That's technically possible with any language. But if I need that to debug my code, then the published spec is inadequate.
Anyway, I've got a more specific critique here. I'd like to see your response to that.
Semantic whitespace makes me sad. :-(
Maybe you never had to work in a large project where the project most productive guy did no care about indentation at all. Whitespace has a semantics for our brain, so we might as well make that consistent with the code. It reduces syntactic noise, in concept programming jargon.
I like to let my IDE correct my indentation in such situations. I know what's coming next... "ah, but the diffs..." but that's a problem with the diffs, not the code. If the diff algorithm treated non-semantic whitespace non-semantically (ie multiple whitespace treated as single whitespace, as an HTML parser does) then it wouldn't be a problem, and the diffs would show up the actual material differences (the changes in start-block and end-block markers), and my IDE could set the indentation depths to my preferences, and adjust them based on screen and font sizes (so that I can debug on a netbook what a colleague wrote on a 24" monitor.
If it is, then the Elm is a lie. Elm claims to be functional, but Tao3D certainly isn't, with prodecures changing obscured persistent state.
The problem with Python is that it's designed to look like other languages.
The problem with BASIC is that it's crap.
Everybody who tries to make a new language these days makes a very similar series of mistakes, under an understandable rationale of either "well, this is the gateway, so it's got to prepare them for 'real' languages" or "the language will never take off if existing programmers find it too alien". When we get to things like GameMaker, you end up with a claim of "programming without programming", but what we find under the hood is a basic C++/Java-lite OO language with crucial programming ideas rechristened with "friendly" names that only serve to further obscure the logic from the programmer.
The only change needed is the addition of labels instead of line numbers as references, and then we could type GOTO HELL, which would make BASIC look self-aware....
Well I suppose it might work... you would have zero velocity after all.... ;-)
I consider the loss of the Challenger criminal negligence, even though no-one was charged. That something so trivial as a silicone O-ring was allowed to kill 7 people and destroy millions of pounds worth of government property was utterly ludicrous. The vehicle had operating temperature specs, and that should have been based on the least tolerant component. Someone must have fiddled the books somewhere along the line.
You completely missed the point, there. Titanic served a useful purpose, it transported people across the sea.
Actually, you missed an important point too. The Titanic's design was a combination of "appeal as much as possible to rich people" and "generate as much profit as possible". The Titanic sank for business reasons, during the great and noble quest for profit. People didn't stop using tried and tested designs when the Titanic sank, they just didn't build another Titanic. Ariane rockets etc have proven pretty trustworthy. It's a fair comparison.
Then perhaps space tourism is a government conspiracy to increase income from inheritance tax...? ;-)
But we have other designs already that are already successful at getting human beings into space and staying there. Space tourism is trying to reduce spaceflight costs, and there is an argument that pricetags vs personal safety don't make for good calculations.
You don't get it. He's not trying to tell you that presentations everywhere are supposed to look like what he demos on the screen, and that everybody must change, he's showing you that there is a great language and environment for making interactive presentations in 3D.
But in his own demos, he trips into the "too much potential results in too much noise" trap -- he adds letter codes to the base proteins in the DNA helix, in default black, then forgets to change the colour before applying the space theme, at which point they're hidden and promptly forgotten about.
Besides, that whole demo has no persistent representation of the structure, except one that is hacked in by spiking the random number generator with a seed so that when the 3D objects are generated from the ground up on every redraw, they look like the same thing. This isn't user-friendly logic.
Let me disappoint then. I don't think you can even write a valid EBNF for XL, it's too dynamic for that. Let me explain why.
[....]
Again, it's "yuck" for formal grammar nazis. But again, I don't care, because it just works.
Except when it doesn't just work and you have to debug, because then what you describe as "dynamic" starts to feel like "unpredictable" and it takes far longer to work through than it should. I've only looked at a very small example, but I cannot imagine myself ever trying to teach how to program in this language. How do you teach someone to think like something with very little internal logic or consistency?
Punters use them to propel their boats. Actually, 12 foot poles are more common, and that's another variation of the phrase. I suspect the phrase refers to punters using their poles to fend off other boats....
Consider it a "video demonstration" then, and consider that it demonstrates some curious weaknesses in the language. (I watched the DNA strand video.)
I don't like subroutine names that include something that looks like a parameter, so things like rotatex and rotatey set me on edge a bit. It gets worse when this is inconsistent, and you see a subroutine called vertical_align for vertical alignment, where the seeming parameter (vertical) is now before the generic (align), and separated by an underscore instead of run together. Not only is this an internal inconsistency, but it's inconsistent with English, as "align" is a verb, and we would put in an adverb "vertically" after the verb normally. And then it gets worse again, as the command for horizontal alignment is... "align".
The grammatical inconsistency continues with other commands/subroutines taking on names with no verb component at all (eg the command color, with no verb or assignment operator.
I'm really not happy with the way pattern matching is used as overloading:
dna_base_color 0 -> color "red" ...
dna_base_color 1 -> color "blue"
rather than a single structure with explicit choices, eg
dna_base_color : ...
0 -> color "red"
| 1 -> color "blue"
...because you can get yourself in a mess if you split it up into different parts of the code and accidentally overwrite stuff.
I'm completely baffled why the whole demo recreates the shapes for every single redraw frame rather than keeping them as persistent objects (which necessitates adding a random seed in order to fake them being persistent by pulling up the same colours each time.
(The demo also demonstrates the whole potential of doing too much and drowning yourself in flash -- notice how DNA letter codes are added, then promptly disappear in a black-on-black clash and are forgotten about.)
But the worst part is the way these rotations and coloring statements create a hidden state that affects things below in an opaque manner... and I'm not even sure it might not effect stuff above it.
There's a remarkable similarity between everything I've just said and the criticisms I've read of processing/processing.js (eg Bret Victor's opinions on Khan Academy's coding tutorials), so I'm guessing this was very heavily inspired by Processing's 2D canvasses....
Nah, I have found that English doesn't really suit my needs, so over time I've have extended it with additional info-enhancefic-features that allow me to wrt +>concs.ly n x that m.mess.g is +>qwk.
Common Lisp macros allow you to create complex language extensions which are not library functions. They perform as though they are built in. Before anyone writes a "new" language they should at least survey the already existing solutions.
Yes, but unfortunately it still leaves you programming in Common Lisp. Lisp was not designed for humans -- it was designed to be easy for the computer to parse. Worse, ukasiewicz's prefix notation may be known as "Polish notation" now, but he called it "parenthesis-free notation" when he invented it (and that was his whole purpose in inventing it), and yet the guys who invented Lisp used prefix with mandatory parenthesis. Lisp was an interesting idea at the time, and dealt with the constraints of the time, but now it's of more use as a study of why the distinction between a "high-level" and "low-level" language isn't exactly clear cut....
Also, requiring "locally" seems to imply that it has one of the worst "features/bugs" of JavaScript design for default globals? Or maybe I did not understand "locally".
The 'locally' function does not concern variables, but graphic state. It's a way to say "I don't want this rotation to escape this block". In OpenGL terminology, you can think of it as a PushMatrix/PopMatrix pair (and same for other attributes).
So does this mean that Tao3D is call-by-value by default, and this explicitly breaks it to (effectively) call-by-value, rather than leaving the programmer to hack around with statics or constants and individual copies of arguments?
I like the clean looking syntax without semicolons at the end of lines. I'm assuming it uses indentation after a comma to define code blocks?
Yes.
Semantic whitespace makes me sad. :-(
can GP name "existing functional languages" (except JS) which don't have a decent lambda syntax?
I don't see the lambda calculus in your example.
That's true, but it's very, very hard to go on a cross-border crusade without very strong support from the people.
That's all fair comment. The power of the Axis forces was, after all, rooted in the unity of feeling the various fascist groups instilled in their populations.
But it's a million miles from the modern myth of France just waving a white flag.
Breaking news: Amelia Earhart has been discovered alive and well on a Pacific island. Doctors in the TIGHAR-sponsored search party say the avatrix is doing well. However, due to her advanced years and resultant dementia, Earhart is unable to identify herself. Ric Gillespie, executive director of TIGHAR, denies that the woman is in fact Mary Montgomery, 74, of New Springs, Idaho, who was reported missing last week after failing to turn up for dinner on board the prestigious cruise ship Pacific Star. Speaking to reporters, Gillespie said "clearly Amelia managed to rig up the components of her radio set into a receiver and heard the story about the missing woman, and due to her advanced cognitive decline, began to associate herself with the news that she heard. Unfortunately, she appears to have lost this radio between hearing the news and our arrival."
...and as Earhart and Noonan squabbled over whether a split infinitive was permissible in English, the plane, unguided, descended into a death spiral.
Come on... the Turin Shroud is a unique and genuinely mystifying artefact (and I say that as someone who doesn't believe in any god). This is... a chunk of metal. with some holes in it.
It can't be water tank -- it's got holes in it, so the water would run out. That only leaves the Earhart theory. Nothing else could be at all possible, no sirree...
The bones found might have been from Amelia Earhart's body. When the measurements of the bones were looked at in 1998 was it noticed that they could have been Earhart's. Thankfully, the internet being what it is, everyone knows her body was found, and that this is an absolute, unquestionable fact.
(How your message looks to a True Believer.)