From: Piotr Trojanek Date: Fri, 22 Mar 2024 18:02:00 +0000 (+0100) Subject: ada: Remove trailing NUL in minimal expansion of Put_Image attribute X-Git-Tag: basepoints/gcc-16~8833 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1bc1fa1160f186b1120bf354f3be3f9b0bf536fb;p=thirdparty%2Fgcc.git ada: Remove trailing NUL in minimal expansion of Put_Image attribute When procedure that implements Put_Image attribute emits the type name, this name was wrongly followed by a NUL character. gcc/ada/ * exp_put_image.adb (Build_Record_Put_Image_Procedure): Remove trailing NUL from the fully qualified type name. --- diff --git a/gcc/ada/exp_put_image.adb b/gcc/ada/exp_put_image.adb index c23b4e24354..f5141a56626 100644 --- a/gcc/ada/exp_put_image.adb +++ b/gcc/ada/exp_put_image.adb @@ -832,7 +832,9 @@ package body Exp_Put_Image is Parameter_Associations => New_List (Make_Identifier (Loc, Name_S), Make_String_Literal (Loc, - To_String (Fully_Qualified_Name_String (Btyp)))))); + To_String + (Fully_Qualified_Name_String + (Btyp, Append_NUL => False)))))); end if; elsif Is_Null_Record_Type (Btyp, Ignore_Privacy => True) then