summaryrefslogtreecommitdiff
path: root/files/practicum/StdStack2.icl
diff options
context:
space:
mode:
Diffstat (limited to 'files/practicum/StdStack2.icl')
-rw-r--r--files/practicum/StdStack2.icl22
1 files changed, 22 insertions, 0 deletions
diff --git a/files/practicum/StdStack2.icl b/files/practicum/StdStack2.icl
new file mode 100644
index 0000000..3d4e80c
--- /dev/null
+++ b/files/practicum/StdStack2.icl
@@ -0,0 +1,22 @@
+implementation module StdStack2
+
+import StdEnv
+
+:: Stack2 elem = E.impl: { stack :: impl
+ , push :: elem impl -> impl
+ , pop :: impl -> impl
+ , top :: impl -> elem
+ , elements :: impl -> [elem]
+ }
+
+push :: elem (Stack2 elem) -> Stack2 elem
+push ...
+
+pop :: (Stack2 elem) -> Stack2 elem
+pop ...
+
+top :: (Stack2 elem) -> elem
+top ...
+
+elements :: (Stack2 elem) -> [elem]
+elements ...