You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Allow adding values to the `!llvm.module.flags` metadata for a generated
module. The syntax is
`-Z llvm_module_flag=<name>:<type>:<value>:<behavior>`
Currently only u32 values are supported but the type is required to be
specified for forward compatibility. The `behavior` element must match
one of the named LLVM metadata behaviors.viors.
This flag is expected to be perma-unstable.
pubconst parse_remap_path_scope:&str = "comma separated list of scopes: `macro`, `diagnostics`, `unsplit-debuginfo`, `split-debuginfo`, `split-debuginfo-path`, `object`, `all`";
431
+
pubconst parse_llvm_module_flag:&str = "<key>:<type>:<value>:<behavior>. Type must currently be `u32`. Behavior should be one of (`error`, `warning`, `require`, `override`, `append`, `appendunique`, `max`, `min`)";
431
432
}
432
433
433
434
mod parse {
@@ -1310,6 +1311,33 @@ mod parse {
1310
1311
};
1311
1312
true
1312
1313
}
1314
+
1315
+
pub(crate)fnparse_llvm_module_flag(
1316
+
slot:&mutVec<(String,u32,String)>,
1317
+
v:Option<&str>,
1318
+
) -> bool{
1319
+
let elements = v.unwrap_or_default().split(':').collect::<Vec<_>>();
0 commit comments