Rename Nullable::Some to Nullable::NotNull #16603
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
A few reasons:
Nullable
is basically unused, save for one argument in theglob
function inliblibc
, so this change likely impacts nobody negatively. The constructors are never used, and I don't foresee people using them. The people implementing the glob functionality don't seem to be reaching for this POSIXglob
function, so it seems unlikely to be used heavily.Some
, needlessly conflicted with the same re-exported name in the prelude, which impacted everybody who use glob imports withlibc
. Changing it to something else would simplify things greatly for those people.NotNull
seemed like the best option (others includedJust
,Valid
, etc. which all had somewhat different connotations than what this type was going for (evenSome
doesn't quite seem like the opposite ofNull
)). Other options included removing the type completely and adding a special,glob
-specific type. This latter approach doesn't seem future-proof.Overall, I feel like this is a mildly positive change.