summaryrefslogtreecommitdiff
path: root/usr.bin/m4
diff options
context:
space:
mode:
authorMarc Espie <espie@cvs.openbsd.org>2003-06-29 11:04:04 +0000
committerMarc Espie <espie@cvs.openbsd.org>2003-06-29 11:04:04 +0000
commitaf0aa20e62c6e8abe5188530a530a57692bb4e8f (patch)
treeb0605a0f609c1a31756d848d0e84eb364f535e4d /usr.bin/m4
parent14f4537af21dfaa6b783b4cd4d1170025f498f55 (diff)
Explain in more details how define interacts with pushdef/popdef, and
how that varies from an m4 implementation to another. ok jmc@
Diffstat (limited to 'usr.bin/m4')
-rw-r--r--usr.bin/m4/m4.115
1 files changed, 14 insertions, 1 deletions
diff --git a/usr.bin/m4/m4.1 b/usr.bin/m4/m4.1
index e417d32f39a..6481822022f 100644
--- a/usr.bin/m4/m4.1
+++ b/usr.bin/m4/m4.1
@@ -1,4 +1,4 @@
-.\" @(#) $OpenBSD: m4.1,v 1.33 2003/06/27 21:22:52 jmc Exp $
+.\" @(#) $OpenBSD: m4.1,v 1.34 2003/06/29 11:04:03 espie Exp $
.\"
.\" Copyright (c) 1989, 1993
.\" The Regents of the University of California. All rights reserved.
@@ -395,6 +395,19 @@ to allow
.Nm autoconf
to work.
.Pp
+The built-ins
+.Ic pushdef
+and
+.Ic popdef
+handle macro definitions as a stack.
+However,
+.Ic define
+interacts with the stack in an undefined way.
+In this implementation,
+.Ic define
+replaces the top-most definition only.
+Other implementations may erase all definitions on the stack instead.
+.Pp
For portability, one should not use the macros
.Ic builtin ,
.Ic esycmd ,