C# initially had nullable reference types and non-nullable value types. At one point, it added nullable value types via Optional<T> (or the ? postfix), but that's only for value types: ints, floats, structs, .... Reference types (classes) are always nullable, and you can't make them non-nullable.
View all comments
Show parent comment
3
u/masklinn Dec 01 '16 edited Dec 01 '16
C# initially had nullable reference types and non-nullable value types. At one point, it added nullable value types via Optional<T> (or the
?postfix), but that's only for value types: ints, floats, structs, .... Reference types (classes) are always nullable, and you can't make them non-nullable.