Migration to Unicode
This is a summary of the recommendations for adapting applications to handle Unicode. Although some recommendations can be applied in earlier version of EiffelStudio starting from 5.6, the following recommendations are made for 7.2 and higher.
- Never use
STRING_8or any variant of it unless you write a program that is going to be deleted in 5 minutes after running it. Do not even consider using
STRING_8or its variant. Always use
- Do not use classes from third-party libraries that take
PATHto manipulate file or directory names
- Whenever an API takes a READABLE_STRING_GENERAL argument, assume that STRING_8 will be treated as Unicode strings in the range 0 .. 255, unless explicitly noted.
- Replace types using the following table:
- Consider using
READABLE_STRING_32for argument types. If you cannot immediately change argument types to take
READABLE_STRING_32, e.g. because this is a library class, use
READABLE_STRING_GENERALand perform all the necessary conversions inside the routine.
- If you need to convert one UTF encoding into another one, use
UTF_CONVERTER. This is an expanded class, so it's possible to declare a local variable of this type and call features on it without explicit object creation.