From 3452b72add26c27bc06d6fb037d73d8c781773ac Mon Sep 17 00:00:00 2001 From: Patrick Pelissier Date: Sat, 15 Sep 2018 15:30:03 +0200 Subject: [PATCH] Fix regression of M*LIB: oplist of tuple/variant wasn't able to detect the default INIT creation as no valid OPLIST was passed in the absence of OPLIST. Give the explicit default OPLIST in this case. --- m-tuple.h | 2 +- m-variant.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/m-tuple.h b/m-tuple.h index bab34a70..2be25373 100644 --- a/m-tuple.h +++ b/m-tuple.h @@ -37,7 +37,7 @@ USAGE: TUPLE_OPLIST(name[, oplist of the first type, ...]) */ #define TUPLE_OPLIST(...) \ M_IF_NARGS_EQ1(__VA_ARGS__) \ - (TUPLEI_OPLIST(__VA_ARGS__, () ), \ + (TUPLEI_OPLIST(__VA_ARGS__, M_DEFAULT_OPLIST ), \ TUPLEI_OPLIST(__VA_ARGS__ )) /* Return an array suitable for the _cmp_order function. diff --git a/m-variant.h b/m-variant.h index 9cc7e16b..f0b52ea3 100644 --- a/m-variant.h +++ b/m-variant.h @@ -40,7 +40,7 @@ USAGE: VARIANT_OPLIST(name[, oplist of the first type, ...]) */ #define VARIANT_OPLIST(...) \ M_IF_NARGS_EQ1(__VA_ARGS__) \ - (VARIANTI_OPLIST(__VA_ARGS__, () ), \ + (VARIANTI_OPLIST(__VA_ARGS__, M_DEFAULT_OPLIST), \ VARIANTI_OPLIST(__VA_ARGS__ ))