hoaproject / Option

The Hoa\Option library.
https://hoa-project.net/
9 stars 3 forks source link

feat(prelude) Add `Some` and `None` in a prelude #2

Closed Hywan closed 7 years ago

Hywan commented 7 years ago

The prelude is autoloaded by Composer, so that Hoa\Option\Some and Hoa\Option\None are always loaded. It is possible to write this:

use function Hoa\Option\{Some, None};

$x = Some(42);
$y = None();
coveralls commented 7 years ago

Coverage Status

Coverage remained the same at 100.0% when pulling 226b7419c53c5904dfbfe609993c5c98a86c3946 on Hywan:prelude into c0e5813da67f98ebe549e917f1aaaaa98f33eb5d on hoaproject:master.

coveralls commented 7 years ago

Coverage Status

Coverage remained the same at 100.0% when pulling 226b7419c53c5904dfbfe609993c5c98a86c3946 on Hywan:prelude into c0e5813da67f98ebe549e917f1aaaaa98f33eb5d on hoaproject:master.