Description
Admin comment: This is activaly being worked on, see dart-lang/language#110 and https://dart.dev/null-safety
This issue was originally filed by cflew...@gmail.com
Short version: Null pointers are a really good way to mess up a program at runtime, and I'd like the Dart team to reevaluate whether they're absolutely required.
Slightly longer version: I would say the #1 cause of issues in my programs (excluding logical errors/requirements errors) are NPEs. Having a language support NPE removal, be it via some clever compiler warning or simply removing null altogether, would be wonderful. I'm personally partial to Scala's method of null removal, but I'm sure PL gurus like yourselves have seen many others.
Dart has a stated goal of avoiding the creation of programs that "are difficult to debug or maintain." NPEs are a huge pain point in this regard. I'd be really happy if the Dart team reevaluated whether they are absolutely required to achieve the other aims.