Update Coding environment
parent
412ec6e231
commit
6c0659033c
@ -10,3 +10,35 @@ One early question is: how might we present 3D scenes of constructions to people
|
|||||||
* [threepp](https://github.com/markaren/threepp), a C++ port of three.js, in case we decide that C++ is our target and it's hard to mix and therefore we need to be using a C++ graphical library
|
* [threepp](https://github.com/markaren/threepp), a C++ port of three.js, in case we decide that C++ is our target and it's hard to mix and therefore we need to be using a C++ graphical library
|
||||||
* Or various other C++ graphics libraries if we need to go there for the same reason, e.g. [Magnum](https://magnum.graphics/)
|
* Or various other C++ graphics libraries if we need to go there for the same reason, e.g. [Magnum](https://magnum.graphics/)
|
||||||
|
|
||||||
|
## Language desiderata
|
||||||
|
This section is very Glen-opinionated ;-)
|
||||||
|
Non-negotiable items:
|
||||||
|
* Clean, non-noisy, DRY syntax, which implies significant indentation for certain (since we will always indent code anyway!), essentially no braces or such delimiters for code grouping, elimination of parentheses to the extent possible, etc.
|
||||||
|
* Strong static typing with a well-developed type system
|
||||||
|
* Able to compile to a browser-executable format (JavaScript or WASM)
|
||||||
|
* Able to call some existing significant body of packages so we don't have to reinvent the wheel
|
||||||
|
|
||||||
|
Other items
|
||||||
|
(should be fleshed out, but things like easy lists and dicts, nice comprehension expressions for them, what else?)
|
||||||
|
|
||||||
|
Here let's try to collect various language options, with their pros and cons:
|
||||||
|
|
||||||
|
### Civet
|
||||||
|
+ Nicest syntax I've ever used
|
||||||
|
- Tied to the dreadful TypeScript type system (probably disqualifying)
|
||||||
|
|
||||||
|
### Nim
|
||||||
|
+ Nice rational syntax with lots of features
|
||||||
|
- Clunky comprehensions (see the examples on the home page) and dicts not first-class with good literal notation. (Oddly, {"a": "b", "c": "d"} appears to be a literal representation for a fixed-length array of pairs of strings. So in particular, the types in each pair have to match, and all pairs must be the same type. But it's hard to find documentation about this, which is somewhat worrisome.)
|
||||||
|
- Some odd rigidity, such as indentation for continuing expressions is only allowed in certain special places like after a binary operator or a parenthesis. Araq, the "benevolent overlord" of Nim, definitely displays his opinionated rigidity on the forums. Of course, maybe that's what it takes to see a new language through to success...
|
||||||
|
|
||||||
|
### Lobster
|
||||||
|
(Is this worth a more careful comparison with Nim, or is it just too small/fringe?)
|
||||||
|
|
||||||
|
### Scala, now with significant indentation
|
||||||
|
(I think targeting the JVM invalidates this?)
|
||||||
|
|
||||||
|
### C++ with our own civet-like syntax mangler
|
||||||
|
- Big con: we would have to implement this!
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user