feat: add stable executable knowledge symbols

This commit is contained in:
cflmy committed 2026-10-23 08:24:10 +00:00
1 parent 92de46aca4
commit 0bbe735c3c
13 files changed
+841 -40

No files matched your search

+1 -1
View File
@@ -5,4 +5,4 @@ import helpers:../structure/ns/helpers.mq.md
# main
> helpers.Box.tag s=x
> helpers.Box.type_name
+14
View File
@@ -490,6 +490,20 @@ fn bytecode_ns_use() {
assert_out_backend("tests/structure/ns/use.mq.md", "bytecode", "hi");
}
#[test]
fn structure_ns_associated_function() {
assert_out("tests/structure/ns/associated.mq.md", "associated\n701");
}
#[test]
fn bytecode_ns_associated_function() {
assert_out_backend(
"tests/structure/ns/associated.mq.md",
"bytecode",
"associated\n701",
);
}
#[test]
fn error_ns_instance_method() {
assert_err(
+14
View File
@@ -0,0 +1,14 @@
---
title: receiver-free object children are associated executable knowledge
import helpers:helpers.mq.md
---
# main
**year = helpers.Box.tag(s="associated")**
> print text=`year`
**also = helpers.Box.birth_year**
> print text=`also`
+8
View File
@@ -17,3 +17,11 @@ Nested free function (not an object method) for `helpers.pack.label`.
+ `s`
*s*
## birth_year
*701*
## type_name
*`self`*