summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2017-09-22 12:10:15 -0700
committerOri Bernstein <ori@eigenstate.org>2017-09-22 12:10:15 -0700
commit444b77956c15d1895a64891ca16f8313fdb00b9c (patch)
tree73f1e0a2d939916f13512baf8ea58d63010a0d85 /test
parent0de1c881850c5fec2183b2e59cd10b8931cd93a4 (diff)
downloadmc-444b77956c15d1895a64891ca16f8313fdb00b9c.tar.gz
Fix trait lookup for nested pointers.
Diffstat (limited to 'test')
-rw-r--r--test/pkgtrait.myr13
-rw-r--r--test/tests1
2 files changed, 14 insertions, 0 deletions
diff --git a/test/pkgtrait.myr b/test/pkgtrait.myr
new file mode 100644
index 0000000..7825937
--- /dev/null
+++ b/test/pkgtrait.myr
@@ -0,0 +1,13 @@
+use std
+use regex
+
+impl disposable regex.regex# =
+ __dispose__ = {r
+ regex.free(r)
+ }
+;;
+
+const main = {
+ var auto r : regex.regex#
+ r = std.try(regex.compile(".*"))
+}
diff --git a/test/tests b/test/tests
index 07fffaa..3f8342d 100644
--- a/test/tests
+++ b/test/tests
@@ -86,6 +86,7 @@ B multistr E 0
B generic E 42
B genericval E 42
B trait-builtin E 42
+B pkgtrait E 42
B gtrait P '`std.Before '
B emptytrait E 123
B traitimpl P 246,44,meee