I am not sure about this method. It seems expensive. Can we maybe just use a hardcoded (possibly incomplete) list of known ASCII-Superset-Encodings instead?