theia-ide / sprotty

A next-gen web-based graphics framework
Apache License 2.0
138 stars 23 forks source link

Enabled strict null checking #10

Closed spoenemann closed 7 years ago

spoenemann commented 7 years ago

Fixes #7.

JanKoehnlein commented 7 years ago

I completely agree we should enable strict null checking.

But I'd like to restrict the use of the bang operator ! to the fewest possible cases. It is more like a very low-profile @SuppressWarnings than an assertion. If it remains unseen after a refactoring, it will easily yield the same problems as a missing check for nullor undefined. I marked a few places where I think we could have better solutions. My feeling is we should not end up with a lot of usages (if any).