Skip to content
Snippets Groups Projects
Commit f7c8ffaa authored by Etienne Kneuss's avatar Etienne Kneuss
Browse files

Let's not discriminate against these two good integers

parent ff4fd365
No related branches found
No related tags found
No related merge requests found
......@@ -41,7 +41,7 @@ package object lang {
def apply(b: String): scala.math.BigInt = scala.math.BigInt(b)
def unapply(b: scala.math.BigInt): scala.Option[Int] = {
if(b > Integer.MIN_VALUE && b < Integer.MAX_VALUE) {
if(b >= Integer.MIN_VALUE && b <= Integer.MAX_VALUE) {
scala.Some(b.intValue())
} else {
scala.None
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment