From 78d16fef9e4212296da937983662e90b3e56c715 Mon Sep 17 00:00:00 2001 From: David Tschumperle Date: Mon, 29 Jan 2024 11:15:53 +0100 Subject: [PATCH] . --- CImg.h | 1 + 1 file changed, 1 insertion(+) diff --git a/CImg.h b/CImg.h index 7291cc74..b3d8deb0 100644 --- a/CImg.h +++ b/CImg.h @@ -18041,6 +18041,7 @@ namespace cimg_library { // Check for particular case to be simplified. if ((op==mp_self_add || op==mp_self_sub) && !arg2) _cimg_mp_return(arg1); if ((op==mp_self_mul || op==mp_self_div || op==mp_self_pow) && arg2==1) _cimg_mp_return(arg1); + if (op==mp_self_pow) { CImg::vector((ulongT)mp_copy,arg1,1).move_to(code); _cimg_mp_return(arg1); } // Apply operator on a copy to prevent modifying a constant or a variable. if (*ref && (_cimg_mp_is_const_scalar(arg1) || _cimg_mp_is_vector(arg1) || _cimg_mp_is_reserved(arg1)))