https://gcc.gnu.org/bugzilla/show_bug.cgi?id=101385

            Bug ID: 101385
           Summary: -Werror doesn't have effect on Ada frontend
           Product: gcc
           Version: 11.1.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ada
          Assignee: unassigned at gcc dot gnu.org
          Reporter: mytbk920423 at gmail dot com
  Target Milestone: ---

I try to make the GCC Ada compiler error when there're warnings, but -Werror
doesn't work.

$ gcc -c -O2 -Werror test.adb && echo "Command returns $?"
test.adb:3:22: warning: value not in range of type "MyChar" defined at line 2
test.adb:3:22: warning: "Constraint_Error" will be raised at run time
Command returns 0

$ gnatmake test.adb -cargs -Werror && echo "Command returns $?"
gcc -c -Werror test.adb
test.adb:3:22: warning: value not in range of type "MyChar" defined at line 2
test.adb:3:22: warning: "Constraint_Error" will be raised at run time
gnatbind -x test.ali
gnatlink test.ali
gnatlink: warning: executable name "test" may conflict with shell command
Command returns 0

Reply via email to