[flang-commits] [clang] [flang] [flang][driver] add negative from of -fsave-main-program (PR #124110)
Eugene Epshteyn via flang-commits
flang-commits at lists.llvm.org
Thu Jan 23 06:03:40 PST 2025
================
@@ -6968,8 +6968,8 @@ defm unsigned : OptInFC1FFlag<"unsigned", "Enables UNSIGNED type">;
def fno_automatic : Flag<["-"], "fno-automatic">, Group<f_Group>,
HelpText<"Implies the SAVE attribute for non-automatic local objects in subprograms unless RECURSIVE">;
-def fsave_main_program : Flag<["-"], "fsave-main-program">, Group<f_Group>,
- HelpText<"Place all variables from the main program in static memory (otherwise scalars may be placed on the stack)">;
+defm save_main_program : OptInFC1FFlag<"save-main-program",
----------------
eugeneepshteyn wrote:
Question on `OptInFC1FFlag` usage. It's definition:
```
multiclass OptInFC1FFlag<string name, string pos_prefix, string neg_prefix="",
string help="",
list<OptionVisibility> vis=[ClangOption]> {
```
So with the current usage, doesn't it assign "save-main-program" to `name` and then the help text to `pos_prefix`?
https://github.com/llvm/llvm-project/pull/124110
More information about the flang-commits
mailing list