s/expression_eq/equal_variables/ to match the behavior
This commit is contained in:
parent
2a8edb53da
commit
b47b5b1c37
@ -489,7 +489,7 @@ and transpile_annotated_expression (ae:AST.expression) : expression result =
|
||||
| AST.E_record_update {record=record'; path=path'; update=update'} -> (
|
||||
match record'.expression_content with
|
||||
| AST.E_record_accessor {record;path} ->
|
||||
if (AST.Misc.expression_eq record r && path = p) then
|
||||
if (AST.Misc.equal_variables record r && path = p) then
|
||||
aux res' (record',path',update')
|
||||
else ok @@ (up,res')
|
||||
| _ -> ok @@ (up,res')
|
||||
|
@ -528,7 +528,7 @@ let program_environment (program : program) : full_environment =
|
||||
match last_declaration with
|
||||
| Declaration_constant { binder=_ ; expr=_ ; inline=_ ; post_env } -> post_env
|
||||
|
||||
let expression_eq a b : bool =
|
||||
let equal_variables a b : bool =
|
||||
match a.expression_content, b.expression_content with
|
||||
| E_variable a, E_variable b -> Var.equal a b
|
||||
| _, _ -> false
|
||||
|
@ -9,7 +9,8 @@ val merge_annotation : type_expression option -> type_expression option -> error
|
||||
|
||||
(* No information about what made it fail *)
|
||||
val type_expression_eq : ( type_expression * type_expression ) -> bool
|
||||
val expression_eq : expression -> expression -> bool
|
||||
|
||||
val equal_variables : expression -> expression -> bool
|
||||
|
||||
module Free_variables : sig
|
||||
type bindings = expression_variable list
|
||||
|
Loading…
Reference in New Issue
Block a user