Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
dtschump committed Mar 10, 2024
2 parents b7061ed + 64e8a0c commit 4a7e1e7
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions CImg.h
Original file line number Diff line number Diff line change
Expand Up @@ -21301,8 +21301,10 @@ namespace cimg_library {
try { arg1 = compile(ss6,se1,depth1,0,block_flags); }
catch(CImgException&) { _cimg_mp_return(0); }
if (is_vector(arg1)) _cimg_mp_vector1_v(mp_isint,arg1);
if (is_const_scalar(arg1))
_cimg_mp_return((unsigned int)((double)(longT)mem[arg1]==mem[arg1]));
if (is_const_scalar(arg1)) {
val = mem[arg1];
_cimg_mp_return((unsigned int)(std::modf(mem[arg1],&val1)?0:(val==0) + 2*(val>0) + 4*(val<0)));
}
_cimg_mp_scalar1(mp_isint,arg1);
}

Expand Down Expand Up @@ -26241,7 +26243,8 @@ namespace cimg_library {
}

static double mp_isint(_cimg_math_parser& mp) {
return (double)((double)(longT)_mp_arg(2)==_mp_arg(2));
double val = _mp_arg(2), intpart;
return std::modf(val,&intpart)?0:(val==0) + 2*(val>0) + 4*(val<0);
}

static double mp_isfile(_cimg_math_parser& mp) {
Expand Down

0 comments on commit 4a7e1e7

Please sign in to comment.