test-46
This commit is contained in:
parent
1f1e58f84f
commit
bfb79a12ce
1 changed files with 6 additions and 4 deletions
|
@ -49,10 +49,12 @@ let rec check_pattern_linearity
|
|||
|
||||
and linearity_variable v vars =
|
||||
if List.mem v.value vars
|
||||
then
|
||||
then (
|
||||
match v.value with
|
||||
| Id i ->
|
||||
HopixTypes.type_error
|
||||
v.position
|
||||
"Il y a déjà une occurence de la variable dans le pattern"
|
||||
(Printf.sprintf "The variable %s has already appeared in this pattern." i))
|
||||
else v.value :: vars
|
||||
|
||||
and linearity_pattern_list plist vars =
|
||||
|
|
Reference in a new issue