Type system
Strong typing. Optional static typing. The compiler will try to deduct types by itself. All functions are initially compiled to a universal implementation that checks types in the runtime, and then if (possible) precise types are known, specialized version are created.
Typed objects don’t accept nil by default:
Stringwill accept anyStringor any subclass ofStringString?will also acceptnilString!will accept only concrete objects of typeString, but not subclasses
If MyClass is a leaf (final) class, then MyClass is equal to MyClass!.
Last revised: 2017-05-19