[m-rev.] for review: Build string switch tries in the target string encoding.
jfischer at opturion.com
Mon Mar 23 11:53:12 AEDT 2015
On Tue, 17 Mar 2015, Peter Wang wrote:
> Build string switch tries in the target string encoding.
> The compiler should work in code units of the TARGET string encoding
> when building tries for string switches. Using its own string encoding
> would be incorrect if it differs from the target encoding. Currently
> that would only occur if the compiler is built in a java/csharp grade
> (uses UTF-16 internally) and invoked to target high-level C (uses UTF-8).
> Another motivation for this change is to remove a place where the
> compiler behaviour depends on the setting of `--cross-compiling'.
> Add new module with helper predicates.
> Convert strings to/from code units in the target string
> Remove restriction on compiling string switches using tries when
> `--cross-compiling' is enabled.
> Document the new module.
That looks fine.
More information about the reviews