mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Add a full.carbon min-prelude that pulls in the full production prelude (#5703)
The `full.carbon` prelude just sets a flag indicating an explicit intent to include the full prelude. Once all tests include some prelude file, an error can be enabled (currently it's commented out) that requires an `INCLUDE-FILE` of some min-prelude to be present in all `check/` and `lower/` file tests.
This commit is contained in:
@@ -282,7 +282,7 @@ to be specified in the compile command line.
|
||||
Excludes files with the given prefix from dumps.
|
||||
)""",
|
||||
},
|
||||
[&](auto& arg_b) { arg_b.Set(&exclude_dump_file_prefix); });
|
||||
[&](auto& arg_b) { arg_b.Append(&exclude_dump_file_prefixes); });
|
||||
b.AddFlag(
|
||||
{
|
||||
.name = "debug-info",
|
||||
@@ -508,12 +508,13 @@ class MultiUnitCache {
|
||||
private:
|
||||
auto BuildIncludeInDumps() -> void {
|
||||
CARBON_CHECK(include_in_dumps_.empty());
|
||||
llvm::append_range(include_in_dumps_,
|
||||
llvm::map_range(units_, [&](const auto& unit) {
|
||||
return options_->exclude_dump_file_prefix.empty() ||
|
||||
!unit->input_filename().starts_with(
|
||||
options_->exclude_dump_file_prefix);
|
||||
}));
|
||||
llvm::append_range(
|
||||
include_in_dumps_, llvm::map_range(units_, [&](const auto& unit) {
|
||||
return llvm::none_of(
|
||||
options_->exclude_dump_file_prefixes, [&](auto prefix) {
|
||||
return unit->input_filename().starts_with(prefix);
|
||||
});
|
||||
}));
|
||||
}
|
||||
|
||||
auto BuildTreeAndSubtreesGetters() -> void {
|
||||
|
||||
Reference in New Issue
Block a user