An interface where four properties are optional describes many states that cannot occur, and the type system cannot help with any of them. Narrowing on the discriminant is…
Square-bracket values let any CSS value be written inline, which is what makes adoption possible and what makes a codebase unmaintainable if it becomes the norm. The moment…
clone copies the initialised state of a readonly property, so modifying the copy throws and every wither has to construct a new instance. The verbosity compounds: a value…
Enums are final, cannot extend anything and cannot be extended, which removes a set of designs that class constants had allowed. Implementing an interface is what makes an…
8.1 on 25 November, and the feature PHP had been simulating with class constants for a decade. A status column holding three spellings of the same thing.
A constructor with an optional dependency needed a null default and a line of null-coalescing, in every class that had one. The exclusion of property defaults is the…
8.1, and a keyword that removes a getter per property. Forty value objects, each with private fields and public accessors that existed only to prevent writes.