This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Ada] fix bug in g-regpat


Tested on i686-linux, committed on trunk

This check in fixes the following scenario:
with GNAT.Regpat; use GNAT.Regpat;
procedure Main is
  PM  : constant Pattern_Matcher := Compile ("[[:xdigit:]]");
  PM2 : constant Pattern_Matcher := Compile ("[[:xxxxx:]]");
begin
  Dump (PM);
end Main;
which clearly shows that we expect any character in ":[dgitx" and where
no error is reported for PM2

2007-04-06  Emmanuel Briot  <briot@adacore.com>

	* g-regpat.adb (Parse_Posix_Character_Class): Fix handling of
	[[:xdigit:]] character class.
	Also raise an exception when an invalid character class is used.

Attachment: difs
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]