diff options
Diffstat (limited to 'src/tools/tool-options.h')
-rw-r--r-- | src/tools/tool-options.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/tools/tool-options.h b/src/tools/tool-options.h index 0522b5538..02b825079 100644 --- a/src/tools/tool-options.h +++ b/src/tools/tool-options.h @@ -156,7 +156,19 @@ struct ToolOptions : public Options { Options::Arguments::Zero, [](Options* o, const std::string& argument) { setTypeSystem(TypeSystem::Isorecursive); - }); + }) + .add( + "--closed-world", + "-cw", + "Assume code outside of the module does not inspect or interact with " + "GC and function references, even if they are passed out. The outside " + "may hold on to them and pass them back in, but not inspect their " + "contents or call them.", + ToolOptionsCategory, + Options::Arguments::Zero, + [this](Options*, const std::string&) { + passOptions.closedWorld = true; + }); } ToolOptions& addFeature(FeatureSet::Feature feature, |