aboutsummaryrefslogtreecommitdiff
path: root/tests/struct_priv_trait_cont/struct.ek
diff options
context:
space:
mode:
Diffstat (limited to 'tests/struct_priv_trait_cont/struct.ek')
-rw-r--r--tests/struct_priv_trait_cont/struct.ek32
1 files changed, 32 insertions, 0 deletions
diff --git a/tests/struct_priv_trait_cont/struct.ek b/tests/struct_priv_trait_cont/struct.ek
new file mode 100644
index 0000000..6c94aaa
--- /dev/null
+++ b/tests/struct_priv_trait_cont/struct.ek
@@ -0,0 +1,32 @@
+pub typedef ptr {};
+pub typedef i27 {};
+
+pub define trait[] {
+ do_something(=> i27);
+}
+
+pub typedef implementer {}
+continue implementer {
+ trait![];
+ do_something(=> i27)
+ {
+ return 0;
+ }
+}
+
+pub typedef struct[trait T] {
+ T a;
+
+ call_something(*struct![T] self)
+ {
+ self*.a.do_something();
+ }
+}
+
+pub some_func()
+{
+ mut p = struct![implementer]{
+ .a = implementer!{}
+ };
+ p.call_something();
+}