pub prints: Vec<PrintRequest>,
pub cg: CodegenOptions,
pub color: ColorConfig,
+ pub show_span: Option<String>,
pub externs: HashMap<String, Vec<String>>,
pub crate_name: Option<String>,
/// An optional name to use as the crate for std during std injection,
prints: Vec::new(),
cg: basic_codegen_options(),
color: Auto,
+ show_span: None,
externs: HashMap::new(),
crate_name: None,
alt_std_name: None,
BORROWCK_STATS,
NO_LANDING_PADS,
DEBUG_LLVM,
- SHOW_SPAN,
COUNT_TYPE_SIZES,
META_STATS,
GC,
("no-landing-pads", "omit landing pads for unwinding",
NO_LANDING_PADS),
("debug-llvm", "enable debug output from LLVM", DEBUG_LLVM),
- ("show-span", "show spans for compiler debugging", SHOW_SPAN),
("count-type-sizes", "count the sizes of aggregate types",
COUNT_TYPE_SIZES),
("meta-stats", "gather metadata statistics", META_STATS),
`flowgraph=<nodeid>` (graphviz formatted flowgraph for node), or
`everybody_loops` (all function bodies replaced with `loop {}`).",
"TYPE"),
+ opt::opt_u("", "show-span", "Show spans for compiler debugging", "expr|pat|ty"),
opt::flagopt("", "dep-info",
"Output dependency info to <filename> after compiling, \
in a format suitable for use by Makefiles", "FILENAME"),
None => early_error("--extern value must be of the format `foo=bar`"),
};
- match externs.entry(name.to_string()) {
- Vacant(entry) => { entry.set(vec![location.to_string()]); },
+ match externs.entry(&name.to_string()) {
+ Vacant(entry) => { entry.insert(vec![location.to_string()]); },
Occupied(mut entry) => { entry.get_mut().push(location.to_string()); },
}
}
prints: prints,
cg: cg,
color: color,
+ show_span: None,
externs: externs,
crate_name: crate_name,
alt_std_name: None,