Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
|
|
@ -0,0 +1,2 @@
|
|||
red (1 2 3 4) (3 2 1 5) .
|
||||
--> (4 5 1 2 3):Int
|
||||
|
|
@ -0,0 +1,19 @@
|
|||
mod! NO-DUP-LIST(ELEMENTS :: TRIV) {
|
||||
op __ : Elt Elt -> Elt { comm assoc idem assoc }
|
||||
}
|
||||
|
||||
-- Runs on Version 1.5.1(PigNose0.99) of CafeOBJ
|
||||
-- The tests are performed after opening instantiated NO-DUP-LIST with various concrete types.
|
||||
-- Test on lists of INT
|
||||
open NO-DUP-LIST(INT) .
|
||||
red 2 1 2 1 2 1 3 .
|
||||
-- Gives (2 1 3):Int
|
||||
open NO-DUP-LIST(INT) .
|
||||
reduce 1 1 2 1 1 .
|
||||
close
|
||||
open NO-DUP-LIST(CHARACTER) .
|
||||
reduce 'a' 'b' 'a' 'a' .
|
||||
close
|
||||
open NO-DUP-LIST(STRING) .
|
||||
reduce "abc" "def" "abc" "abc" "abc" .
|
||||
close
|
||||
Loading…
Add table
Add a link
Reference in a new issue