File tree Expand file tree Collapse file tree 2 files changed +12
-0
lines changed
Expand file tree Collapse file tree 2 files changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -34,6 +34,12 @@ instance : LE Timestamp where
3434instance { x y : Timestamp } : Decidable (x ≤ y) :=
3535 inferInstanceAs (Decidable (x.val ≤ y.val))
3636
37+ instance : LT Timestamp where
38+ lt x y := x.val < y.val
39+
40+ instance { x y : Timestamp } : Decidable (x < y) :=
41+ inferInstanceAs (Decidable (x.val < y.val))
42+
3743instance : OfNat Timestamp n where
3844 ofNat := ⟨OfNat.ofNat n⟩
3945
Original file line number Diff line number Diff line change @@ -156,6 +156,12 @@ instance : LE Duration where
156156instance {x y : Duration} : Decidable (x ≤ y) :=
157157 inferInstanceAs (Decidable (x.toNanoseconds ≤ y.toNanoseconds))
158158
159+ instance : LT Duration where
160+ lt d1 d2 := d1.toNanoseconds < d2.toNanoseconds
161+
162+ instance {x y : Duration} : Decidable (x < y) :=
163+ inferInstanceAs (Decidable (x.toNanoseconds < y.toNanoseconds))
164+
159165/--
160166Converts a `Duration` to a `Minute.Offset`
161167-/
You can’t perform that action at this time.
0 commit comments