summaryrefslogtreecommitdiff
path: root/data/stack.hh
diff options
context:
space:
mode:
authorAkim Demaille <akim@lrde.epita.fr>2012-05-21 14:21:51 +0200
committerAkim Demaille <akim@lrde.epita.fr>2012-05-21 18:15:41 +0200
commit22172d473180c53755290f13ebd2d53e12e74fe0 (patch)
tree804555fc790cf45753ad437509d12f0177ed68cf /data/stack.hh
parenta19728cbb5efdac48c97ef6e6c997f2534c03391 (diff)
downloadbison-22172d473180c53755290f13ebd2d53e12e74fe0.tar.gz
c++: compute the header guards.
This is a frequent request. Recently pointed out by Wei Song, <http://lists.gnu.org/archive/html/help-bison/2012-05/msg00002.html>. * data/c.m4 (b4_tocpp, b4_cpp_guard, b4_cpp_guard_open) (b4_cpp_guard_close): New. * data/lalr1.cc, data/location.cc, data/stack.hh: Use them. * TODO (Header Guards): Move to... * NEWS: here. Formatting changes.
Diffstat (limited to 'data/stack.hh')
-rw-r--r--data/stack.hh6
1 files changed, 2 insertions, 4 deletions
diff --git a/data/stack.hh b/data/stack.hh
index 52933774..ddedc79b 100644
--- a/data/stack.hh
+++ b/data/stack.hh
@@ -30,8 +30,7 @@ b4_copyright([Stack handling for Bison parsers in C++],
** Define the ]b4_namespace_ref[::stack class.
*/
-#ifndef BISON_STACK_HH
-# define BISON_STACK_HH
+]b4_cpp_guard_open([b4_dir_prefix[]stack.hh])[
# include <deque>
@@ -119,8 +118,7 @@ b4_copyright([Stack handling for Bison parsers in C++],
};
]b4_namespace_close[
-#endif // not BISON_STACK_HH[]dnl
-]
+]b4_cpp_guard_close([b4_dir_prefix[]stack.hh])
m4_divert_pop(0)
m4_popdef([b4_copyright_years])dnl
m4_changecom([#])