elves / elvish

Powerful scripting language & versatile interactive shell
https://elv.sh/
BSD 2-Clause "Simplified" License
5.63k stars 299 forks source link

Compile-time safety, statical analysis, types, assert, etc. #1370

Closed dumblob closed 2 years ago

dumblob commented 3 years ago

Hi, newbie here.

I couldn't find much information about compile-time safety checking of the given Elvish program. Could you shed some light on that? The more detailed, the better.

Thanks!

xiaq commented 3 years ago

Names of local variables are statically checked: https://elv.sh/ref/language.html#variable-use

There isn't much else going on right now. Some kind of static type checking (in a very general sense of the word "type") is likely useful, but type-checking dynamic languages is far from a solved problem.