I think it has already been reported elsewhere, but IIRC there is no #if
that lets us check for the version of the standard library (not to be mismatched with the version of the compiler). This makes it difficult to use such features in code intended to compile on multiple toolchains (i.e. libraries).
Edit: I found a previous thread on the topic: Introduce `#if stdlib` or clarify `#if swift`