Language Design: Modern and Minimal
Published on 2019-11-05. Last updated on 2022-12-06
- A smaller language, not a bigger one
- namespaces: types, terms,
packages,fields,methods,labels - modifiers:
keywords, annotations - nesting:
packages, modules,static - members: fields, methods,
properties - control flow: if-then-else, return, while,
break,continue,loop,exceptions,throw,catch - constructors: primary,
secondary - literals:
octal number literals,class literals, …
- namespaces: types, terms,
- Correctness
- separate types for identity/equality, ordering/comparing
- Fewer special-cases, not more
- operators:
unary operators, fewer binary operators magic methods on all typescollection literals,array syntaxinstance-of-syntax,cast-syntax- types have consistent casing (uppercase)
- operators:
- Simplicity, not familiarity
generics with <>- member definition syntax differs only by
fun
,let
orvar
- Higher Standards
- simple to specify
- simple to implement
- simple to understand