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
C
clean-libraries
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
3
Issues
3
List
Boards
Labels
Service Desk
Milestones
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
clean-and-itasks
clean-libraries
Commits
cf79df7a
Commit
cf79df7a
authored
Aug 12, 2019
by
johnvg@science.ru.nl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add RECORD instance of gMap
parent
2ee170a4
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
Libraries/GenLib/GenMap.dcl
Libraries/GenLib/GenMap.dcl
+1
-1
Libraries/GenLib/GenMap.icl
Libraries/GenLib/GenMap.icl
+1
-1
No files found.
Libraries/GenLib/GenMap.dcl
View file @
cf79df7a
...
...
@@ -3,6 +3,6 @@ definition module GenMap
import
StdGeneric
generic
gMap
a
b
::
.
a
->
.
b
derive
gMap
c
,
UNIT
,
PAIR
,
EITHER
,
CONS
,
FIELD
,
OBJECT
,
{},
{!}
derive
gMap
c
,
UNIT
,
PAIR
,
EITHER
,
CONS
,
RECORD
,
FIELD
,
OBJECT
,
{},
{!}
derive
gMap
[],
(,),
(,,),
(,,,),
(,,,,),
(,,,,,),
(,,,,,,),
(,,,,,,,)
Libraries/GenLib/GenMap.icl
View file @
cf79df7a
...
...
@@ -10,10 +10,10 @@ gMap{|PAIR|} fx fy (PAIR x y) = PAIR (fx x) (fy y)
gMap
{|
EITHER
|}
fl
fr
(
LEFT
x
)
=
LEFT
(
fl
x
)
gMap
{|
EITHER
|}
fl
fr
(
RIGHT
x
)
=
RIGHT
(
fr
x
)
gMap
{|
CONS
|}
f
(
CONS
x
)
=
CONS
(
f
x
)
gMap
{|
RECORD
|}
f
(
RECORD
x
)
=
RECORD
(
f
x
)
gMap
{|
FIELD
|}
f
(
FIELD
x
)
=
FIELD
(
f
x
)
gMap
{|
OBJECT
|}
f
(
OBJECT
x
)
=
OBJECT
(
f
x
)
gMap
{|{}|}
f
xs
=
mapArray
f
xs
gMap
{|{!}|}
f
xs
=
mapArray
f
xs
derive
gMap
[],
(,),
(,,),
(,,,),
(,,,,),
(,,,,,),
(,,,,,,),
(,,,,,,,)
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