Provides predicates for working with numeric values and their string
representations.
Import path
import codeql.NumberUtils
Predicates
| eightToThe | Gets the value of 8 to the power of n. Holds only for n in the range 0..10 (inclusive).
|
| parseBinaryInt | Gets the integer value of binary when interpreted as binary. binary must contain only the digits 0 and 1. For values greater than 01111111111111111111111111111111 (2^31-1, the maximum value that int can represent), there is no result.
|
| parseHexInt | Gets the integer value of hex when interpreted as hex. hex must be a valid hexadecimal string. For values greater than 7FFFFFFF (2^31-1, the maximum value that int can represent), there is no result.
|
| parseOctalInt | Gets the integer value of octal when interpreted as octal. octal must be a valid octal string containing only the digits 0-7. For values greater than 17777777777 (2^31-1, the maximum value that int can represent), there is no result.
|
| sixteenToThe | Gets the value of 16 to the power of n. Holds only for n in the range 0..7 (inclusive).
|
| twoToThe | Gets the value of 2 to the power of n. Holds only for n in the range 0..30 (inclusive).
|