Rust: integrate into standard files+location library

This commit is contained in:
Paolo Tranquilli
2024-09-12 13:15:46 +02:00
parent a4c1ec75db
commit b4b680775c
43 changed files with 445 additions and 1221 deletions

View File

@@ -14,3 +14,8 @@ rust_library(
],
deps = all_crate_deps(),
)
filegroup(
name = "dbscheme-prefix",
srcs = ["src/generator/prefix.dbscheme"],
)

View File

@@ -154,7 +154,7 @@ fn global_location(writer: &mut trap::Writer, location: trap::Location) -> trap:
/** Get the label for the given location, creating it as a fresh ID if we haven't seen the location
* yet for this file. */
fn location_label(writer: &mut trap::Writer, location: trap::Location) -> trap::Label {
pub fn location_label(writer: &mut trap::Writer, location: trap::Location) -> trap::Label {
let (loc_label, fresh) = writer.location_label(location);
if fresh {
writer.add_tuple(