Introduce package level `canSearchInCodeUnits`

And use it to solve bugs/simplify code.
Merge pull request #1517 from monarchdodra/fitsInCodeUnit

Fix bugs using `fitsInCodeUnit`
fixup issue  11479 and enum --> auto in examples
Merge pull request #1692 from blackwhale/bad-doc

[TRIVIAL] Fixup docs in std.regex