]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
a68: remove unimplemented math functions from is_mappable_routine
authorJose E. Marchesi <jemarch@gnu.org>
Sun, 10 May 2026 10:16:24 +0000 (12:16 +0200)
committerJose E. Marchesi <jemarch@gnu.org>
Sun, 10 May 2026 10:16:24 +0000 (12:16 +0200)
The is_mappable_routine function has to identify all routines that are
lengthety-mapped.  This includes math functions like sin and cos.

This patch removes the handling of several math routines that we are
not implementing as compiler builtins:

arccosdg   cbrt     curt       gammaincgf
arccotdg   cosdg     erf       sindg
arcsindg   cospi     erfc       sinpi
arctandg   cot     gamma       tandg
beta   cotdg     gammainc       tanpi
betainc   cotpi     gammaincg

If these routines ever get added to the extended standard prelude, it
will be as regular procedures rather than compiler builtins.

Signed-off-by: Jose E. Marchesi <jemarch@gnu.org>
Reported-by: "Nelson H. F. Beebe" <beebe@math.utah.edu>
gcc/algol68/ChangeLog

* a68-parser-taxes.cc (is_mappable_routine): Remove handling of
non-implemented math functions.

gcc/algol68/a68-parser-taxes.cc

index 6227732ebc6416327bdb9048df62241768d1ca64..52065531f6b1d1934c509c2704bb8c0646055c8d 100644 (file)
@@ -142,41 +142,17 @@ is_mappable_routine (const char *z)
 
   /* Math routines.  */
   ACCEPT (z, "arccos");
-  ACCEPT (z, "arccosdg");
   ACCEPT (z, "arccot");
-  ACCEPT (z, "arccotdg");
   ACCEPT (z, "arcsin");
-  ACCEPT (z, "arcsindg");
   ACCEPT (z, "arctan");
-  ACCEPT (z, "arctandg");
-  ACCEPT (z, "beta");
-  ACCEPT (z, "betainc");
-  ACCEPT (z, "cbrt");
   ACCEPT (z, "cos");
-  ACCEPT (z, "cosdg");
-  ACCEPT (z, "cospi");
-  ACCEPT (z, "cot");
-  ACCEPT (z, "cot");
-  ACCEPT (z, "cotdg");
-  ACCEPT (z, "cotpi");
-  ACCEPT (z, "curt");
-  ACCEPT (z, "erf");
-  ACCEPT (z, "erfc");
   ACCEPT (z, "exp");
-  ACCEPT (z, "gamma");
-  ACCEPT (z, "gammainc");
-  ACCEPT (z, "gammaincg");
-  ACCEPT (z, "gammaincgf");
   ACCEPT (z, "ln");
   ACCEPT (z, "log");
   ACCEPT (z, "pi");
   ACCEPT (z, "sin");
-  ACCEPT (z, "sindg");
-  ACCEPT (z, "sinpi");
   ACCEPT (z, "sqrt");
   ACCEPT (z, "tan");
-  ACCEPT (z, "tandg");
-  ACCEPT (z, "tanpi");
   /* Random generator.  */
   ACCEPT (z, "nextrandom");
   ACCEPT (z, "random");