Enforce unique top-level names for tests too.
This prevents the compiler from crashing later on. Test names should be unique and not clash with function names.
This commit is contained in:
@@ -995,6 +995,7 @@ impl<'a> Environment<'a> {
|
||||
}
|
||||
|
||||
Definition::Test(Function { name, location, .. }) => {
|
||||
assert_unique_value_name(names, name, location)?;
|
||||
hydrators.insert(name.clone(), Hydrator::new());
|
||||
let arg_types = vec![];
|
||||
let return_type = builtins::bool();
|
||||
|
||||
Reference in New Issue
Block a user