mirror of
https://github.com/zaphar/ucg.git
synced 2025-07-21 18:10:42 -04:00
This is a breaking change for the language. However it makes a number of things easier. Like importing specific symbols from a file. adds: #28
16 lines
419 B
Plaintext
16 lines
419 B
Plaintext
let shared = import "./libs/shared.ucg";
|
|
let test_mod = (import "./libs/shared.ucg").test_mod{};
|
|
|
|
let script = include str "./include_example.sh";
|
|
|
|
assert {
|
|
ok = script == test_mod.script,
|
|
desc = "include path worked from an imported module",
|
|
};
|
|
|
|
let imported = (import "./libs/test_import.ucg").val;
|
|
|
|
assert {
|
|
ok = imported == test_mod.imported,
|
|
desc = "include path worked from an imported module",
|
|
}; |