From: Viljar Indus <[email protected]>

The error message here was using both ?.*? and ? warning
inseriton characters where the latter would override the first.

gcc/ada/ChangeLog:

        * sem_disp.adb (Warn_On_Late_Primitive_After_Private_Extension):
        apply warning character correctly.

Tested on x86_64-pc-linux-gnu, committed on master.

---
 gcc/ada/sem_disp.adb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/ada/sem_disp.adb b/gcc/ada/sem_disp.adb
index f69e7959ee5..c093d1122d0 100644
--- a/gcc/ada/sem_disp.adb
+++ b/gcc/ada/sem_disp.adb
@@ -1243,7 +1243,7 @@ package body Sem_Disp is
                   Error_Msg_Sloc := Sloc (E);
                   Error_Msg_N
                     ("?.j?primitive of type % defined after private extension "
-                     & "% #?", Prim);
+                     & "% #", Prim);
                   Error_Msg_Name_1 := Chars (Prim);
                   Error_Msg_Name_2 := Chars (E);
                   Error_Msg_N
-- 
2.53.0

Reply via email to