Another solution would've been to merge it into OperatingSystem::MacOSX, and just ignore that "darwin" doesn't technically mean that (though it is likely to in practice). If we chose this solution (which would be focusing more on rustc targets), I would probably not want to parse the version at all, and just ignore it instead.
Also allow it to be optional, or partially specified.
This is a breaking change.
I've chosen to keep
Darwin
as a separate OS, since it seems like in https://github.com/bytecodealliance/target-lexicon/issues/111#issuecomment-2388418787 that this crate wants to focus on LLVM target triples.Another solution would've been to merge it into
OperatingSystem::MacOSX
, and just ignore that"darwin"
doesn't technically mean that (though it is likely to in practice). If we chose this solution (which would be focusing more onrustc
targets), I would probably not want to parse the version at all, and just ignore it instead.