[COMMITTED] a68: remove unimplemented math functions from is_mappable_routine

Jose E. Marchesi jemarch@gnu.org
Sun May 10 10:31:35 GMT 2026


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 | 24 ------------------------
 1 file changed, 24 deletions(-)

diff --git a/gcc/algol68/a68-parser-taxes.cc b/gcc/algol68/a68-parser-taxes.cc
index 6227732ebc6..52065531f6b 100644
--- a/gcc/algol68/a68-parser-taxes.cc
+++ b/gcc/algol68/a68-parser-taxes.cc
@@ -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");
-- 
2.39.5



More information about the Algol68 mailing list