summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog1
-rw-r--r--src/arith.y40
-rw-r--r--src/builtins.def1
3 files changed, 1 insertions, 41 deletions
diff --git a/ChangeLog b/ChangeLog
index 13fc33f..41d99b4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,7 @@
 	* Replaced EXEVAL with SKIPEVAL.
 	* Update funcnest atomically.
 	* Only set skipcount for break and continue.
+	* Removed expcmd built-in.
 
 2005-02-28  A Costa <agcosta@gis.net>
 
diff --git a/src/arith.y b/src/arith.y
index be836c8..35d012d 100644
--- a/src/arith.y
+++ b/src/arith.y
@@ -137,46 +137,6 @@ arith(s)
 }
 
 
-/*
- *  The exp(1) builtin.
- */
-int
-expcmd(argc, argv)
-	int argc;
-	char **argv;
-{
-	const char *p;
-	char *concat;
-	char **ap;
-	long i;
-
-	if (argc > 1) {
-		p = argv[1];
-		if (argc > 2) {
-			/*
-			 * concatenate arguments
-			 */
-			STARTSTACKSTR(concat);
-			ap = argv + 2;
-			for (;;) {
-				while (*p)
-					STPUTC(*p++, concat);
-				if ((p = *ap++) == NULL)
-					break;
-				STPUTC(' ', concat);
-			}
-			STPUTC('\0', concat);
-			p = grabstackstr(concat);
-		}
-	} else
-		p = nullstr;
-
-	i = arith(p);
-
-	out1fmt("%ld\n", i);
-	return (! i);
-}
-
 /*************************/
 #ifdef TEST_ARITH
 #include <stdio.h>
diff --git a/src/builtins.def b/src/builtins.def
index 2fa6d5b..1f8c4f4 100644
--- a/src/builtins.def
+++ b/src/builtins.def
@@ -59,7 +59,6 @@ echocmd		echo
 evalcmd		-s eval
 execcmd		-s exec
 exitcmd		-s exit
-expcmd		exp let
 exportcmd	-as export -as readonly
 falsecmd	-u false
 histcmd -h	-u fc