]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[Ada] Fix missing space in error message
authorPiotr Trojanek <trojanek@adacore.com>
Tue, 3 May 2022 12:13:13 +0000 (14:13 +0200)
committerPierre-Marie de Rodat <derodat@adacore.com>
Wed, 1 Jun 2022 08:43:20 +0000 (08:43 +0000)
On illegal code like:

   type T is new Positive in range 1..5;

the compiler was emitting message:

  error: extra "in"ignored
                  ^^

which lacked a space character.

A tiny diagnostic improvement; spotted while mistakenly typing an
illegal test.

gcc/ada/

* par-util.adb (Ignore): Add missing space to message string.

gcc/ada/par-util.adb

index 2eabc58699d6251d781b343d2bd9e0ed332f574d..3f1247a5121a0ec9a12b0983ec2389d3ea2653f2 100644 (file)
@@ -462,7 +462,7 @@ package body Util is
             declare
                Tname : constant String := Token_Type'Image (Token);
             begin
-               Error_Msg_SC ("|extra " & Tname (5 .. Tname'Last) & "ignored");
+               Error_Msg_SC ("|extra " & Tname (5 .. Tname'Last) & " ignored");
             end;
          end if;