diff --git a/integration_tests/modules_test.ucg b/integration_tests/modules_test.ucg index a78ac8b..ac6742e 100644 --- a/integration_tests/modules_test.ucg +++ b/integration_tests/modules_test.ucg @@ -2,6 +2,11 @@ let test_empty_mod = module { } => { }; +let std_lib_import = module { +} => { + let tpl = import "std/tuples.ucg"; +}; + let empty_mod_instance = test_empty_mod{}; let test_simple_mod = module { diff --git a/src/ast/mod.rs b/src/ast/mod.rs index 5eb2202..6dd25e3 100644 --- a/src/ast/mod.rs +++ b/src/ast/mod.rs @@ -545,6 +545,10 @@ impl ModuleDef { } if let Expression::Import(ref mut def) = e { let path = PathBuf::from(&def.path.fragment); + // std/ paths are special and do not get made into absolute paths. + if path.starts_with("std/") { + return; + } if path.is_relative() { def.path.fragment = base .join(path)