public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Iain D Sandoe <iains@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc r13-5156] modula-2: Handle pass '-v' option to the compiler.
Date: Fri, 13 Jan 2023 21:06:57 +0000 (GMT)	[thread overview]
Message-ID: <20230113210657.CD2113858C33@sourceware.org> (raw)

https://gcc.gnu.org/g:1a460d19ba0939e05b38befb6256f4f4bb416e0d

commit r13-5156-g1a460d19ba0939e05b38befb6256f4f4bb416e0d
Author: Iain Sandoe <iain@sandoe.co.uk>
Date:   Thu Jan 12 23:50:53 2023 +0000

    modula-2: Handle pass '-v' option to the compiler.
    
    Somehow this setting had been missed, and we really need the verbose
    flag to enable useful debug output.
    
    Signed-off-by: Iain Sandoe <iain@sandoe.co.uk>
    
    gcc/m2/ChangeLog:
    
            * gm2-gcc/m2options.h (M2Options_SetVerbose): Export the
            function.
            * gm2-lang.cc: Handle OPT_v, passing it to the compiler.
            * lang-specs.h: Pass -v to cc1gm2.

Diff:
---
 gcc/m2/gm2-gcc/m2options.h | 1 +
 gcc/m2/gm2-lang.cc         | 3 +++
 gcc/m2/lang-specs.h        | 2 +-
 3 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/gcc/m2/gm2-gcc/m2options.h b/gcc/m2/gm2-gcc/m2options.h
index 4b32c911b09..beaa460ffa9 100644
--- a/gcc/m2/gm2-gcc/m2options.h
+++ b/gcc/m2/gm2-gcc/m2options.h
@@ -106,6 +106,7 @@ EXTERN int M2Options_GetCpp (void);
 EXTERN int M2Options_GetM2g (void);
 EXTERN void M2Options_SetM2g (int value);
 EXTERN void M2Options_SetLowerCaseKeywords (int value);
+EXTERN void M2Options_SetVerbose (int value);
 EXTERN void M2Options_SetUnusedVariableChecking (int value);
 EXTERN void M2Options_SetUnusedParameterChecking (int value);
 EXTERN void M2Options_SetStrictTypeChecking (int value);
diff --git a/gcc/m2/gm2-lang.cc b/gcc/m2/gm2-lang.cc
index 5814ebf4db6..4f49d073f44 100644
--- a/gcc/m2/gm2-lang.cc
+++ b/gcc/m2/gm2-lang.cc
@@ -407,6 +407,9 @@ gm2_langhook_handle_option (
     case OPT_save_temps_:
       M2Options_SetSaveTempsDir (arg);
       return 1;
+    case OPT_v:
+      M2Options_SetVerbose (value);
+      return 1;
     default:
       if (insideCppArgs)
         {
diff --git a/gcc/m2/lang-specs.h b/gcc/m2/lang-specs.h
index 706064fc8db..44e5b345deb 100644
--- a/gcc/m2/lang-specs.h
+++ b/gcc/m2/lang-specs.h
@@ -33,6 +33,6 @@ along with GCC; see the file COPYING3.  If not see
       "cc1gm2 " M2CPP
       "      %(cc1_options) %{B*} %{c*} %{f*} %{+e*} %{I*} "
       "      %{MD} %{MMD} %{M} %{MM} %{MA} %{MT*} %{MF*} %V"
-      "      %{save-temps*}"
+      "      %{save-temps*} %{v} "
       "      %i %{!fsyntax-only:%(invoke_as)}",
       0, 0, 0},

                 reply	other threads:[~2023-01-13 21:06 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230113210657.CD2113858C33@sourceware.org \
    --to=iains@gcc.gnu.org \
    --cc=gcc-cvs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).