This commit is contained in:
swrup 2025-11-11 02:07:51 +01:00
parent aa2ff7b2f0
commit 2f3113f55d
11742 changed files with 1223940 additions and 0 deletions

View file

@ -0,0 +1,43 @@
open Ppx_compare_lib.Builtin
type t =
{ x : int [@compare.ignore]
; y : int
}
[@@deriving equal]
[%%expect
{|
Line _, characters _-_:
Error: Cannot use [@compare.ignore] with [@@deriving equal]
|}]
type t =
{ x : int [@equal.ignore]
; y : int
}
[@@deriving compare, equal]
[%%expect
{|
Line _, characters _-_:
Error: Cannot use [@equal.ignore] with [@@deriving compare].
|}]
(* The following ones are OK: *)
type t =
{ x : int [@compare.ignore] [@equal.ignore]
; y : int
}
[@@deriving compare, equal]
[%%expect {| |}]
type t =
{ x : int [@ignore]
; y : int
}
[@@deriving compare, equal]
[%%expect {| |}]