Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cduce
cduce
Commits
09152eed
Commit
09152eed
authored
Apr 11, 2014
by
Julien Lopez
Browse files
[TESTS][LAMBDA] Fix environment for pairs in match
parent
3932c71c
Changes
1
Show whitespace changes
Inline
Side-by-side
tests/lambda/src/compute.ml
View file @
09152eed
...
...
@@ -162,11 +162,11 @@ and parse_match_value env l list p toptype = match p with
line
cbegin
cend
;
Printf
.
eprintf
" type %s is not a pair
\n
"
(
Types
.
Print
.
to_string
(
type_of_ptype
toptype
));
raise
Error
)
in
let
t1
,
d1
,
list
,
l
,
b1
=
parse_match_value
env
l
list
m1
top1
in
let
t2
,
d2
,
list
,
l
,
b2
=
parse_match_value
env
l
list
m2
top2
in
let
t1
,
d1
,
list
1
,
l
,
b1
=
parse_match_value
env
l
list
m1
top1
in
let
t2
,
d2
,
list
2
,
l
,
b2
=
parse_match_value
env
l
list
m2
top2
in
times
(
cons
t1
)
(
cons
t2
)
,
Patterns
.
Times
(
make_patterns
t1
[]
d1
,
make_patterns
t2
[]
d2
)
,
list
,
l
,
b1
&&
b2
;
Patterns
.
Times
(
make_patterns
t1
list1
d1
,
make_patterns
t2
list2
d2
)
,
(
list
1
@
list2
)
,
l
,
b1
&&
b2
;
|
MVar
(
_
,
mname
,
mtype
)
->
let
lsize
=
Locals
.
cardinal
l
in
let
l
=
Locals
.
add
mname
lsize
l
in
...
...
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