dummy[]_b4_char_sizeof_counter])
-# b4_char_sizeof_(SYMBOL-NUM)
-# ---------------------------
-# A comment describing this symbol.
-m4_define([b4_char_sizeof_],
-[ // b4_symbol([$1], [tag])
-])
-
# b4_char_sizeof(SYMBOL-NUMS)
# ---------------------------
# To be mapped on the list of type names to produce:
m4_define([b4_char_sizeof],
[b4_symbol_if([$1], [has_type],
[
-m4_map([b4_char_sizeof_], [$@])dnl
+m4_map([ b4_symbol_tag_comment], [$@])dnl
char _b4_char_sizeof_dummy@{sizeof([b4_symbol([$1], [type])])@};
])])
# The needed includes for variants support.
m4_define([b4_variant_includes],
[b4_parse_assert_if([[#include <typeinfo>]])[
+#include <cstdlib> // abort
#ifndef YYASSERT
# include <cassert>
# define YYASSERT assert
other.destroy<T>();
}
+ /// Copy the content of \a other to this.
+ /// Destroys \a other.
+ template <typename T>
+ inline void
+ copy (const variant<S>& other)
+ {
+ build<T> (other.as<T> ());
+ }
+
/// Destroy the stored \a T.
template <typename T>
inline void
tname = YY_NULL;])[
}
+ /// Prohibit blind copies.
+ // private:
+ self_type& operator=(const self_type&)
+ {
+ abort ();
+ }
+
private:
/// A buffer large enough to store any of the semantic values.
/// Long double is chosen as it has the strongest alignment