Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Scala's Option monad versus null-conditional operator in C#. Parent comment
Ruby 2.3 &. operator and Swift can do something like this pseudocode:
if let city = article?.author?.address?.city?.ToLower() { // city present }
if let city = article? .author? .address? .city? .ToLower() { // city present }
(Be aware of subtle gotcha in Scala of var and val, really prefer Rust/Go/Swift keywords.)
There are no comments on this comment yet.
Ruby 2.3 &. operator and Swift can do something like this pseudocode:
Too long?: All are improvements over pyramids of doom.(Be aware of subtle gotcha in Scala of var and val, really prefer Rust/Go/Swift keywords.)