[Ada] Fix wrong code for case statement on character

Eric Botcazou ebotcazou@adacore.com
Sat Jun 11 11:56:00 GMT 2016


This fixes a regression present on the mainline and 6 branch, whereby the 
compiler generates wrong code for a case statement whose expression is of the 
standard Character type and which contains a large range of values among other 
things.

Tested on x86_64-suse-linux, applied on the mainline and 6 branch.


2016-06-11  Eric Botcazou  <ebotcazou@adacore.com>

	* gcc-interface/trans.c (Case_Statement_to_gnu): Deal with characters.


2016-06-11  Eric Botcazou  <ebotcazou@adacore.com>

	* gnat.dg/case_character.adb: New test.

-- 
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p.diff
Type: text/x-patch
Size: 1773 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20160611/acaa2205/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: case_character.adb
Type: text/x-adasrc
Size: 303 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20160611/acaa2205/attachment-0001.bin>


More information about the Gcc-patches mailing list