-
Notifications
You must be signed in to change notification settings - Fork 24.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Painless] Add extensive tests for def to primitive casts (#36455)
This adds tests for each possible cast of def to a primitive type both implicit and explicit. This also fixes a minor bug where we were only checking the type of a def to be Number in some explicit casts. This does not work because it allows possible unintended casts from BigInteger and BigDecimal to primitive types since they both extend Number but are not included as part of the Painless casting model.
- Loading branch information
Showing
3 changed files
with
449 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.