Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
StdEnv-doc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Cloogle
StdEnv-doc
Commits
8fa71b85
Commit
8fa71b85
authored
Jun 14, 2013
by
John van Groningen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
try to fix newlines
parent
bdeaceb4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
256 additions
and
256 deletions
+256
-256
StdEnv 64 Changed Files/_SystemStrictLists.icl
StdEnv 64 Changed Files/_SystemStrictLists.icl
+256
-256
No files found.
StdEnv 64 Changed Files/_SystemStrictLists.icl
View file @
8fa71b85
implementation
module
_SystemStrictLists
;
class
List
.
l
e
where
{
_cons
::
.
e
u
:(
l
.
e
)
->
u
:(
l
.
e
);
_decons
::
!
u
:(
l
.
e
)
->
(.
e
,
u
:(
l
.
e
));
};
class
UList
e
where
{
_cons_u
::
!.
e
u
:[#.
e
]
->
u
:[#.
e
];
_decons_u
::
!
u
:[#.
e
]
->
(!.
e
,
u
:[#.
e
]);
};
class
UTSList
e
where
{
_cons_uts
::
!.
e
!
u
:[#.
e
!]
->
u
:[#.
e
!];
_decons_uts
::
!
u
:[#.
e
!]
->
(!.
e
,!
u
:[#.
e
!]);
};
_nil
::
u
:(
l
.
e
)
|
List
l
e
,
[
u
<=
e
];
_nil
=
code {
pop_a
2
fillh
_Nil
0
0
}
;
_nil_u
::
.[#.
e
]
|
UList
e
;
_nil_u
=
code {
pop_a
2
fillh
_Nil
0
0
}
;
_nil_uts
::
.[#.
e
!]
|
UTSList
e
;
_nil_uts
=
code {
pop_a
2
fillh
_Nil
0
0
}
;
instance
List
[]
a
where
{
_cons
a
b
=
[
a
:
b
];
_decons
[
a
:
b
]
=
(
a
,
b
);
}
instance
List
[!]
a
where
{
_cons
a
b
=
[!
a
:
b
];
_decons
[!
a
:
b
]
=
(
a
,
b
);
}
instance
List
[
!]
a
where
{
_cons
a
b
=
[
a
:
b
!];
_decons
[
a
:
b
!]
=
(
a
,
b
);
}
instance
List
[!!]
a
where
{
_cons
a
b
=
[!
a
:
b
!];
_decons
[!
a
:
b
!]
=
(
a
,
b
);
}
instance
List
[#]
a
|
UList
a
where
{
_cons
a
b
=
_cons_u
a
b
;
_decons
a
=
_decons_u
a
;
}
instance
List
[#!]
a
|
UTSList
a
where
{
_cons
a
b
=
_cons_uts
a
b
;
_decons
a
=
_decons_uts
a
;
}
instance
UList
a
where
{
_cons_u
a
b
=
code {
print
"_cons_u of UList a"
halt
}
;
_decons_u
_
=
code {
print
"_decons_u of UList a"
halt
}
}
instance
UList
Int
where
{
_cons_u
a
b
=
code {
fill_r
_Consi
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
1
}
}
instance
UList
Real
where
{
_cons_u
a
b
=
code {
fill_r
_Consr
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
2
}
}
instance
UList
Char
where
{
_cons_u
a
b
=
code {
fill_r
_Consc
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
1
}
}
instance
UList
Bool
where
{
_cons_u
a
b
=
code {
fill_r
_Consb
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
1
}
}
instance
UList
File
where
{
_cons_u
a
b
=
code {
fill_r
_Consf
1
2
1
0
0
pop_b
2
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
2
}
}
instance
UList
{.
a
}
where
{
_cons_u
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_u
a
=
code {
repl_r_args
2
0
}
}
instance
UList
{!.
a
}
where
{
_cons_u
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_u
a
=
code {
repl_r_args
2
0
}
}
instance
UList
{#.
a
}
where
{
_cons_u
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_u
a
=
code {
repl_r_args
2
0
}
}
instance
UTSList
a
where
{
_cons_uts
a
b
=
code {
print
"_cons_uts of UTSList a"
halt
}
;
_decons_uts
_
=
code {
print
"_decons_uts of UTSList a"
halt
}
}
instance
UTSList
Int
where
{
_cons_uts
a
b
=
code {
fill_r
_Consits
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
1
}
}
instance
UTSList
Real
where
{
_cons_uts
a
b
=
code {
fill_r
_Consrts
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
2
}
}
instance
UTSList
Char
where
{
_cons_uts
a
b
=
code {
fill_r
_Conscts
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
1
}
}
instance
UTSList
Bool
where
{
_cons_uts
a
b
=
code {
fill_r
_Consbts
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
1
}
}
instance
UTSList
File
where
{
_cons_uts
a
b
=
code {
fill_r
_Consfts
1
2
1
0
0
pop_b
2
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
2
}
}
instance
UTSList
{.
a
}
where
{
_cons_uts
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_uts
a
=
code {
repl_r_args
2
0
}
}
instance
UTSList
{!.
a
}
where
{
_cons_uts
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_uts
a
=
code {
repl_r_args
2
0
}
}
instance
UTSList
{#.
a
}
where
{
_cons_uts
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_uts
a
=
code {
repl_r_args
2
0
}
}
implementation
module
_SystemStrictLists
;
class
List
.
l
e
where
{
_cons
::
.
e
u
:(
l
.
e
)
->
u
:(
l
.
e
);
_decons
::
!
u
:(
l
.
e
)
->
(.
e
,
u
:(
l
.
e
));
};
class
UList
e
where
{
_cons_u
::
!.
e
u
:[#.
e
]
->
u
:[#.
e
];
_decons_u
::
!
u
:[#.
e
]
->
(!.
e
,
u
:[#.
e
]);
};
class
UTSList
e
where
{
_cons_uts
::
!.
e
!
u
:[#.
e
!]
->
u
:[#.
e
!];
_decons_uts
::
!
u
:[#.
e
!]
->
(!.
e
,!
u
:[#.
e
!]);
};
_nil
::
u
:(
l
.
e
)
|
List
l
e
,
[
u
<=
e
];
_nil
=
code {
pop_a
2
fillh
_Nil
0
0
}
;
_nil_u
::
.[#.
e
]
|
UList
e
;
_nil_u
=
code {
pop_a
2
fillh
_Nil
0
0
}
;
_nil_uts
::
.[#.
e
!]
|
UTSList
e
;
_nil_uts
=
code {
pop_a
2
fillh
_Nil
0
0
}
;
instance
List
[]
a
where
{
_cons
a
b
=
[
a
:
b
];
_decons
[
a
:
b
]
=
(
a
,
b
);
}
instance
List
[!]
a
where
{
_cons
a
b
=
[!
a
:
b
];
_decons
[!
a
:
b
]
=
(
a
,
b
);
}
instance
List
[
!]
a
where
{
_cons
a
b
=
[
a
:
b
!];
_decons
[
a
:
b
!]
=
(
a
,
b
);
}
instance
List
[!!]
a
where
{
_cons
a
b
=
[!
a
:
b
!];
_decons
[!
a
:
b
!]
=
(
a
,
b
);
}
instance
List
[#]
a
|
UList
a
where
{
_cons
a
b
=
_cons_u
a
b
;
_decons
a
=
_decons_u
a
;
}
instance
List
[#!]
a
|
UTSList
a
where
{
_cons
a
b
=
_cons_uts
a
b
;
_decons
a
=
_decons_uts
a
;
}
instance
UList
a
where
{
_cons_u
a
b
=
code {
print
"_cons_u of UList a"
halt
}
;
_decons_u
_
=
code {
print
"_decons_u of UList a"
halt
}
}
instance
UList
Int
where
{
_cons_u
a
b
=
code {
fill_r
_Consi
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
1
}
}
instance
UList
Real
where
{
_cons_u
a
b
=
code {
fill_r
_Consr
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
2
}
}
instance
UList
Char
where
{
_cons_u
a
b
=
code {
fill_r
_Consc
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
1
}
}
instance
UList
Bool
where
{
_cons_u
a
b
=
code {
fill_r
_Consb
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
1
}
}
instance
UList
File
where
{
_cons_u
a
b
=
code {
fill_r
_Consf
1
2
1
0
0
pop_b
2
pop_a
1
}
;
_decons_u
a
=
code {
repl_r_args
1
2
}
}
instance
UList
{.
a
}
where
{
_cons_u
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_u
a
=
code {
repl_r_args
2
0
}
}
instance
UList
{!.
a
}
where
{
_cons_u
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_u
a
=
code {
repl_r_args
2
0
}
}
instance
UList
{#.
a
}
where
{
_cons_u
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_u
a
=
code {
repl_r_args
2
0
}
}
instance
UTSList
a
where
{
_cons_uts
a
b
=
code {
print
"_cons_uts of UTSList a"
halt
}
;
_decons_uts
_
=
code {
print
"_decons_uts of UTSList a"
halt
}
}
instance
UTSList
Int
where
{
_cons_uts
a
b
=
code {
fill_r
_Consits
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
1
}
}
instance
UTSList
Real
where
{
_cons_uts
a
b
=
code {
fill_r
_Consrts
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
2
}
}
instance
UTSList
Char
where
{
_cons_uts
a
b
=
code {
fill_r
_Conscts
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
1
}
}
instance
UTSList
Bool
where
{
_cons_uts
a
b
=
code {
fill_r
_Consbts
1
1
1
0
0
pop_b
1
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
1
}
}
instance
UTSList
File
where
{
_cons_uts
a
b
=
code {
fill_r
_Consfts
1
2
1
0
0
pop_b
2
pop_a
1
}
;
_decons_uts
a
=
code {
repl_r_args
1
2
}
}
instance
UTSList
{.
a
}
where
{
_cons_uts
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_uts
a
=
code {
repl_r_args
2
0
}
}
instance
UTSList
{!.
a
}
where
{
_cons_uts
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_uts
a
=
code {
repl_r_args
2
0
}
}
instance
UTSList
{#.
a
}
where
{
_cons_uts
a
b
=
code {
fill_r
_Consa
2
0
2
0
0
pop_a
2
}
;
_decons_uts
a
=
code {
repl_r_args
2
0
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment