diff options
author | shrek2000 <oren.kleks@amdocs.com> | 2019-11-28 10:59:30 +0200 |
---|---|---|
committer | shrek2000 <oren.kleks@amdocs.com> | 2019-11-28 10:59:30 +0200 |
commit | 7b089c09caf5c112fe6f3f538ddc6902b79ce384 (patch) | |
tree | 8c9b07ec16e95f1f4fbb117f4ee05de9e49c8a54 /pom.xml | |
parent | c49ad1c995d0cf58ce4a1a99ad635ecc29f8b2a9 (diff) |
Fix Sonar issues
When arithmetic is performed on integers, the result will always be an integer. You can assign that result to a long, double, or float with automatic type conversion, but having started as an int or long, the result will likely not be what you expect.
For instance, if the result of int division is assigned to a floating-point variable, precision will have been lost before the assignment. Likewise, if the result of multiplication is assigned to a long, it may have already overflowed before the assignment.
In either case, the result will not be what was expected. Instead, at least one operand should be cast or promoted to the final type before the operation takes place.
Issue-ID: SDC-2690
Signed-off-by: shrek2000 <oren.kleks@amdocs.com>
Change-Id: I3ef06e48b02a73753a824076d3a9de8b585f2917
Diffstat (limited to 'pom.xml')
0 files changed, 0 insertions, 0 deletions