Skip to content

Commit

Permalink
remove useless exception
Browse files Browse the repository at this point in the history
zapashcanon authored and krtab committed Feb 22, 2024

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
1 parent 2ddc25a commit e412baf
Showing 4 changed files with 0 additions and 8 deletions.
2 changes: 0 additions & 2 deletions src/int32.ml
Original file line number Diff line number Diff line change
@@ -16,8 +16,6 @@ let of_int64 = Int64.to_int32

let to_int64 = Int64.of_int32

exception Overflow

(* Unsigned comparison in terms of signed comparison. *)
let cmp_u x op y = op (add x min_int) (add y min_int)

2 changes: 0 additions & 2 deletions src/int32.mli
Original file line number Diff line number Diff line change
@@ -2,8 +2,6 @@

type t = int32

exception Overflow

val min_int : t

val max_int : t
2 changes: 0 additions & 2 deletions src/int64.ml
Original file line number Diff line number Diff line change
@@ -6,8 +6,6 @@ let clz n = Stdlib.Int64.of_int (Ocaml_intrinsics.Int64.count_leading_zeros n)

let ctz n = Stdlib.Int64.of_int (Ocaml_intrinsics.Int64.count_trailing_zeros n)

exception Overflow

(* Taken from Base: https://github.com/janestreet/base *)
let popcnt =
let ( + ) = add in
2 changes: 0 additions & 2 deletions src/int64.mli
Original file line number Diff line number Diff line change
@@ -2,8 +2,6 @@

type t = int64

exception Overflow

val min_int : t

val max_int : t

0 comments on commit e412baf

Please sign in to comment.