100 n.n = (
n.n <<
v.n) | (
n.n >> (
sizeof(
n.n) * 8 -
v.n));
105 n.n = (
n.n >>
v.n) | (
n.n << (
sizeof(
n.n) * 8 -
v.n));
110 n.d = (
n.d - (
n.d /
v.d));
139 RZ_LOG_WARN(
"floating point powers not yet supported\n");
145 }
else if ((
st64)
v.n < 0) {
200 left =
Nmod(left,
d);
207 left =
Ndiv(left,
d);
293 num->nc.calc_buf =
p;
294 num->nc.calc_len = strlen(
p);
297 return num->nc.calc_buf +
num->nc.calc_i;
336 if (sscanf(
str,
"%lf", &
d) < 1) {
429 error(
num, nc,
"invalid number conversion");
434 #define isvalidchar(x) \
435 (isalnum(x) || (x) == ':' || (x) == '$' || (x) == '.' || (x) == '_' || (x) == '?' || (x) == '\\' || (x) == ' ' || (x) == '[' || (x) == ']' || (x) == '}' || (x) == '{' || ((x) >= '0' && (x) <= '9'))
439 #define stringValueAppend(x) \
441 const size_t max = sizeof(nc->string_value) - 1; \
443 nc->string_value[i++] = x; \
445 nc->string_value[max] = 0; \
static RzNumCalcValue term(RzNum *, RzNumCalc *, int)
static RzNumCalcValue Nexp(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Nneg(RzNumCalcValue n)
static RzNumCalcValue Nset(ut64 v)
static int cin_get_num(RzNum *num, RzNumCalc *nc, RzNumCalcValue *n)
#define stringValueAppend(x)
static RzNumCalcValue Nror(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Nlt(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Ngt(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Nxor(RzNumCalcValue n, RzNumCalcValue v)
static void cin_putback(RzNum *num, RzNumCalc *nc, char c)
static RzNumCalcValue Nshl(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Naddi(RzNumCalcValue n, ut64 v)
static RzNumCalcValue Ndiv(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Nadd(RzNumCalcValue n, RzNumCalcValue v)
static void load_token(RzNum *num, RzNumCalc *nc, const char *s)
static RzNumCalcValue Nmod(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Nand(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue expr(RzNum *, RzNumCalc *, int)
static RzNumCalcValue Nmul(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue prim(RzNum *, RzNumCalc *, int)
static RzNumCalcValue Nsubi(RzNumCalcValue n, ut64 v)
static RzNumCalcToken get_token(RzNum *, RzNumCalc *)
static int cin_get(RzNum *num, RzNumCalc *nc, char *c)
static RzNumCalcValue Nsetf(double v)
static RzNumCalcValue Nrol(RzNumCalcValue n, RzNumCalcValue v)
RZ_API const char * rz_num_calc_index(RzNum *num, const char *p)
RZ_API ut64 rz_num_calc(RzNum *num, const char *str, const char **err)
static RzNumCalcValue Norr(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Nshr(RzNumCalcValue n, RzNumCalcValue v)
static RzNumCalcValue Nsub(RzNumCalcValue n, RzNumCalcValue v)
static void error(RzNum *, RzNumCalc *, const char *)
static static fork const void static count static fd const char const char static newpath char char char static envp time_t static t const char static mode static whence const char static dir time_t static t unsigned static seconds const char struct utimbuf static buf static inc static sig const char static mode static oldfd struct tms static buf static getgid static geteuid const char static filename static arg static mask struct ustat static ubuf static getppid static setsid static egid sigset_t static set struct timeval struct timezone static tz fd_set fd_set fd_set struct timeval static timeout const char char static bufsiz const char static swapflags void static offset const char static length static mode static who const char struct statfs static buf unsigned unsigned num
#define RZ_LOG_WARN(fmtstr,...)
RZ_API ut64 rz_num_get(RzNum *num, const char *str)
RZ_API void rz_str_trim(RZ_NONNULL RZ_INOUT char *str)
Removes whitespace characters (space, tab, newline etc.) from the beginning and end of a string.
RzNumCalcValue number_value
char string_value[RZ_NUMCALC_STRSZ]
ut64(WINAPI *w32_GetEnabledXStateFeatures)()