Ensure unique names for helper procs

This commit is contained in:
Brian Carroll 2021-12-22 09:25:37 +00:00
parent 4a970f089a
commit d33c1b54fd
2 changed files with 3 additions and 3 deletions

View file

@ -325,7 +325,7 @@ impl<'a> CodeGenHelp<'a> {
(*existing_symbol, None)
} else {
let layout_name = layout_debug_name(layout);
let debug_name = format!("#help{:?}_{}", op, layout_name);
let debug_name = format!("#help{:?}_{}_{}", op, layout_name, self.specs.len());
let new_symbol: Symbol = self.create_symbol(ident_ids, &debug_name);
self.specs.push((*layout, op, new_symbol));

View file

@ -481,7 +481,7 @@ fn list_eq_compare_pointwise() {
}
#[test]
#[cfg(any(feature = "gen-llvm"))]
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
fn list_eq_nested() {
assert_evals_to!("[[1]] == [[1]]", true, bool);
assert_evals_to!("[[2]] == [[1]]", false, bool);
@ -495,7 +495,7 @@ fn list_neq_compare_pointwise() {
}
#[test]
#[cfg(any(feature = "gen-llvm"))]
#[cfg(any(feature = "gen-llvm", feature = "gen-wasm"))]
fn list_neq_nested() {
assert_evals_to!("[[1]] != [[1]]", false, bool);
assert_evals_to!("[[2]] != [[1]]", true, bool);