diff --git a/doc/html/boost_config/acknowledgements.html b/doc/html/boost_config/acknowledgements.html index 87d6546a..95301d82 100644 --- a/doc/html/boost_config/acknowledgements.html +++ b/doc/html/boost_config/acknowledgements.html @@ -3,7 +3,7 @@ Acknowledgements - + @@ -21,7 +21,7 @@
PrevUpHome
-
+
diff --git a/doc/html/boost_config/boost_macro_reference.html b/doc/html/boost_config/boost_macro_reference.html index b684de83..b7390a01 100644 --- a/doc/html/boost_config/boost_macro_reference.html +++ b/doc/html/boost_config/boost_macro_reference.html @@ -3,7 +3,7 @@ Boost Macro Reference - + @@ -22,7 +22,7 @@
PrevUpHomeNext
-
+
@@ -44,7 +44,7 @@

-
+

Macros that describe defects @@ -1291,7 +1291,7 @@

-
+
-
+
-
+

Macros that describe C++0x features not supported @@ -2831,12 +2831,24 @@

+ + +

+ BOOST_NO_VARIADIC_MACROS +

+ + +

+ The compiler does not support variadic macros. +

+ +

-
+

Boost Helper Macros @@ -3176,7 +3188,7 @@

-
+

Boost Informational Macros @@ -3454,7 +3466,7 @@

-
+

Macros for libraries with separate source code @@ -3471,14 +3483,14 @@ The following macros and helper headers are of use to authors whose libraries include separate source code, and are intended to address several issues:

-
    -
  • +
      +
    • Controlling shared library symbol visibility
    • -
    • +
    • Fixing the ABI of the compiled library
    • -
    • +
    • Selecting which compiled library to link against based upon the compilers settings
    • @@ -3487,7 +3499,7 @@ See Guidelines for Authors of Boost Libraries Containing Separate Source

      -
      +
      -
      +

      ABI Fixing @@ -3700,7 +3712,7 @@ to point to their own prefix/suffix headers if they so wish.

      -
      +

      Automatic library selection diff --git a/doc/html/boost_config/guidelines_for_boost_authors.html b/doc/html/boost_config/guidelines_for_boost_authors.html index 577bd808..820adb10 100644 --- a/doc/html/boost_config/guidelines_for_boost_authors.html +++ b/doc/html/boost_config/guidelines_for_boost_authors.html @@ -3,7 +3,7 @@ Guidelines for Boost Authors - + @@ -22,7 +22,7 @@
      PrevUpHomeNext
      -
      +

      Guidelines for Boost Authors @@ -61,26 +61,26 @@

      Note that:

      -
        -
      • +
          +
        • Boost library implementers are not required to "#include <boost/config.hpp>", and are not required in any way to support compilers that do not comply with the C++ Standard (ISO/IEC 14882).
        • -
        • +
        • If a library implementer wishes to support some non-conforming compiler, or to support some platform specific feature, "#include <boost/config.hpp>" is the preferred way to obtain configuration information not available from the standard headers such as <climits>, etc.
        • -
        • +
        • If configuration information can be deduced from standard headers such as <climits>, use those standard headers rather than <boost/config.hpp>.
        • -
        • +
        • Boost files that use macros defined in <boost/config.hpp> should have sensible, standard conforming, default behavior if the macro is not defined. This means that the starting point for porting <boost/config.hpp> to a new platform is simply to define @@ -88,22 +88,22 @@ is no sensible default behavior, an #error message should describe the problem.
        • -
        • +
        • If a Boost library implementer wants something added to config.hpp, post a request on the Boost mailing list. There is no guarantee such a request will be honored; the intent is to limit the complexity of config.hpp.
        • -
        • +
        • The intent is to support only compilers which appear on their way to becoming C++ Standard compliant, and only recent releases of those compilers at that.
        • -
        • +
        • The intent is not to disable mainstream features now well-supported by the majority of compilers, such as namespaces, exceptions, RTTI, or templates.
        -
        +

        Disabling Compiler Warnings @@ -116,17 +116,17 @@

        Note that:

        -
          -
        • +
            +
          • This header should never be included by another Boost header, it should only ever be used by a library source file or a test case.
          • -
          • +
          • The header should be included before you include any other header.
          • -
          • +
          • This header only disables warnings that are hard or impossible to otherwise deal with, and which are typically emitted by one compiler only, or in one compilers own standard library headers. @@ -182,7 +182,7 @@
        -
        +

        Adding New Defect Macros @@ -233,15 +233,15 @@ Once the test code is in place in libs/config/test, updating the configuration test system proceeds as:

        -
          -
        • +
            +
          • cd into libs/config/tools and run bjam. This generates the .cpp file test cases from the .ipp file, updates the libs/config/test/all/Jamfile.v2, config_test.cpp and config_info.cpp.

          • -
          • +
          • cd into libs/config/test/all and run bjam MACRONAME compiler-list, where MACRONAME is the name of the new macro, and @@ -253,7 +253,7 @@ is defined when it should not be defined, xxx_fail_test will not report **passed**.

          • -
          • +
          • cd into libs/config/test and run bjam config_info config_test compiler-list. @@ -266,26 +266,26 @@

            Then you should:

            -
              -
            • +
                +
              • Define the defect macro in those config headers that require it.
              • -
              • +
              • Document the macro in this documentation (please do not forget this step!!)
              • -
              • +
              • Commit everything.
              • -
              • +
              • Keep an eye on the regression tests for new failures in Boost.Config caused by the addition.
              • -
              • +
              • Start using the macro.
            -
            +

            Adding New Feature Test Macros @@ -309,7 +309,7 @@ <unistd.h>).

            -
            +

            Modifying the Boost Configuration Headers diff --git a/doc/html/boost_config/rationale.html b/doc/html/boost_config/rationale.html index 4be5310f..e073e213 100644 --- a/doc/html/boost_config/rationale.html +++ b/doc/html/boost_config/rationale.html @@ -3,7 +3,7 @@ Rationale - + @@ -22,7 +22,7 @@
            PrevUpHomeNext
            -
            +
            @@ -39,7 +39,7 @@ principles from the following article.

            -
            +
            @@ -90,7 +90,7 @@ code must be provided.

            -
            +
            diff --git a/doc/html/index.html b/doc/html/index.html index 5a390070..fe1235db 100644 --- a/doc/html/index.html +++ b/doc/html/index.html @@ -3,7 +3,7 @@ Boost.Config - + @@ -18,7 +18,7 @@
            Next
            -
            +

            @@ -28,7 +28,7 @@

            -

            +

            Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

            @@ -92,7 +92,7 @@
            Acknowledgements
            -
            +
            -
            +

            Using the default boost configuration @@ -135,7 +135,7 @@ and submitting a support request.

            -
            +

            The <boost/config.hpp> header @@ -168,7 +168,7 @@

            -
            +

            Using the configure script @@ -289,15 +289,15 @@ (located under <boost-root>/boost/config/). There are two ways you can use this header:

            -
              -
            • +
                +
              • Option 1: copy the header into <boost-root>/boost/config/ so that it replaces the default user.hpp provided by boost. This option allows only one configure-generated setup; boost developers should avoid this option, as it incurs the danger of accidentally committing a configure-modified <boost/config/user.hpp> to the cvs repository (something you will not be thanked for!).
              • -
              • +
              • Option 2: give the header a more memorable name, and place it somewhere convenient; then, define the macro BOOST_USER_CONFIG to point to it. For example create a new sub-directory <boost-root>/boost/config/ user/, and copy the header there; for example @@ -312,7 +312,7 @@

              -
              +

              User settable options @@ -678,7 +678,7 @@

              -
              +

              Advanced configuration usage @@ -722,7 +722,7 @@

              The following usage examples represent just a few of the possibilities:

              -
              +

              Example 1, creating our own frozen configuration @@ -754,7 +754,7 @@ yet supported by boost.

              -
              +

              Example 2: skipping files that you don't need @@ -773,7 +773,7 @@ a dependency on two boost headers.

              -
              +
              -
              +

              Testing the boost configuration @@ -950,7 +950,7 @@

              - +

              Last revised: June 30, 2010 at 23:58:03 GMT

              Last revised: August 17, 2010 at 09:09:56 GMT


              diff --git a/doc/macro_reference.qbk b/doc/macro_reference.qbk index f9d9fcc3..54d2ea2b 100644 --- a/doc/macro_reference.qbk +++ b/doc/macro_reference.qbk @@ -620,6 +620,9 @@ Unicode (`u8`, `u`, `U`) literals. [[`BOOST_NO_VARIADIC_TEMPLATES`][The compiler does not support variadic templates. ]] +[[`BOOST_NO_VARIADIC_MACROS`][The compiler does not support +variadic macros. +]] ] [endsect] diff --git a/include/boost/config/compiler/borland.hpp b/include/boost/config/compiler/borland.hpp index bd3a8c3f..a989fd63 100644 --- a/include/boost/config/compiler/borland.hpp +++ b/include/boost/config/compiler/borland.hpp @@ -46,6 +46,8 @@ // Borland C++Builder 5, command-line compiler 5.5: # define BOOST_NO_OPERATORS_IN_NAMESPACE # endif +// Variadic macros do not exist for C++ Builder versions 5 and below +#define BOOST_NO_VARIADIC_MACROS # endif // Version 5.51 and below: diff --git a/include/boost/config/compiler/clang.hpp b/include/boost/config/compiler/clang.hpp index 85f4484d..2ce67732 100644 --- a/include/boost/config/compiler/clang.hpp +++ b/include/boost/config/compiler/clang.hpp @@ -48,6 +48,7 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES +#define BOOST_NO_VARIADIC_MACROS // HACK: Clang does support extern templates, but Boost's test for // them is wrong. diff --git a/include/boost/config/compiler/common_edg.hpp b/include/boost/config/compiler/common_edg.hpp index cb283376..682c73af 100644 --- a/include/boost/config/compiler/common_edg.hpp +++ b/include/boost/config/compiler/common_edg.hpp @@ -88,12 +88,10 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES +#define BOOST_NO_VARIADIC_MACROS #ifdef c_plusplus // EDG has "long long" in non-strict mode // However, some libraries have insufficient "long long" support // #define BOOST_HAS_LONG_LONG #endif - - - diff --git a/include/boost/config/compiler/digitalmars.hpp b/include/boost/config/compiler/digitalmars.hpp index bd37d2f1..31c11bf0 100644 --- a/include/boost/config/compiler/digitalmars.hpp +++ b/include/boost/config/compiler/digitalmars.hpp @@ -80,6 +80,9 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES +#if (__DMC__ < 0x812) +#define BOOST_NO_VARIADIC_MACROS +#endif #if __DMC__ < 0x800 #error "Compiler not supported or configured - please reconfigure" diff --git a/include/boost/config/compiler/gcc.hpp b/include/boost/config/compiler/gcc.hpp index 54f1bb98..e1c33e0c 100644 --- a/include/boost/config/compiler/gcc.hpp +++ b/include/boost/config/compiler/gcc.hpp @@ -43,6 +43,8 @@ # define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL # define BOOST_NO_IS_ABSTRACT # define BOOST_NO_EXTERN_TEMPLATE +// Variadic macros do not exist for gcc versions before 3.0 +# define BOOST_NO_VARIADIC_MACROS #elif __GNUC__ == 3 # if defined (__PATHSCALE__) # define BOOST_NO_TWO_PHASE_NAME_LOOKUP diff --git a/include/boost/config/compiler/gcc_xml.hpp b/include/boost/config/compiler/gcc_xml.hpp index 7f884b19..48fb4533 100644 --- a/include/boost/config/compiler/gcc_xml.hpp +++ b/include/boost/config/compiler/gcc_xml.hpp @@ -35,6 +35,7 @@ # define BOOST_NO_RVALUE_REFERENCES # define BOOST_NO_STATIC_ASSERT # define BOOST_NO_VARIADIC_TEMPLATES +# define BOOST_NO_VARIADIC_MACROS # define BOOST_NO_AUTO_DECLARATIONS # define BOOST_NO_AUTO_MULTIDECLARATIONS # define BOOST_NO_CHAR16_T @@ -49,6 +50,7 @@ # define BOOST_NO_LAMBDAS # define BOOST_NO_RAW_LITERALS # define BOOST_NO_UNICODE_LITERALS +# define BOOST_NO_VARIADIC_MACROS #define BOOST_COMPILER "GCC-XML C++ version " __GCCXML__ diff --git a/include/boost/config/compiler/hp_acc.hpp b/include/boost/config/compiler/hp_acc.hpp index 98e7772a..d0b672ec 100644 --- a/include/boost/config/compiler/hp_acc.hpp +++ b/include/boost/config/compiler/hp_acc.hpp @@ -115,6 +115,16 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES + +/* + See https://forums13.itrc.hp.com/service/forums/questionanswer.do?threadId=1443331 and + https://forums13.itrc.hp.com/service/forums/questionanswer.do?threadId=1443436 +*/ + +#if (__HP_aCC < 62500) || !defined(HP_CXX0x_SOURCE) + #define BOOST_NO_VARIADIC_MACROS +#endif + #endif // diff --git a/include/boost/config/compiler/metrowerks.hpp b/include/boost/config/compiler/metrowerks.hpp index 3bc9d975..21083b7a 100644 --- a/include/boost/config/compiler/metrowerks.hpp +++ b/include/boost/config/compiler/metrowerks.hpp @@ -114,6 +114,7 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES +#define BOOST_NO_VARIADIC_MACROS #define BOOST_COMPILER "Metrowerks CodeWarrior C++ version " BOOST_STRINGIZE(BOOST_COMPILER_VERSION) diff --git a/include/boost/config/compiler/mpw.hpp b/include/boost/config/compiler/mpw.hpp index 4db14dde..ae12f801 100644 --- a/include/boost/config/compiler/mpw.hpp +++ b/include/boost/config/compiler/mpw.hpp @@ -63,6 +63,7 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES +#define BOOST_NO_VARIADIC_MACROS // // versions check: diff --git a/include/boost/config/compiler/nvcc.hpp b/include/boost/config/compiler/nvcc.hpp index e31c3e28..eaecf374 100644 --- a/include/boost/config/compiler/nvcc.hpp +++ b/include/boost/config/compiler/nvcc.hpp @@ -37,6 +37,7 @@ #define BOOST_HAS_DIRENT_H #define BOOST_HAS_CLOCK_GETTIME #define BOOST_NO_VARIADIC_TEMPLATES +#define BOOST_NO_VARIADIC_MACROS #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_STD_UNORDERED diff --git a/include/boost/config/compiler/pgi.hpp b/include/boost/config/compiler/pgi.hpp index 1c7c84b7..fb3a6c0b 100644 --- a/include/boost/config/compiler/pgi.hpp +++ b/include/boost/config/compiler/pgi.hpp @@ -70,6 +70,7 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES +#define BOOST_NO_VARIADIC_MACROS // // version check: diff --git a/include/boost/config/compiler/sunpro_cc.hpp b/include/boost/config/compiler/sunpro_cc.hpp index aca49fa0..85fa4625 100644 --- a/include/boost/config/compiler/sunpro_cc.hpp +++ b/include/boost/config/compiler/sunpro_cc.hpp @@ -122,6 +122,7 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES +#define BOOST_NO_VARIADIC_MACROS // // Version diff --git a/include/boost/config/compiler/vacpp.hpp b/include/boost/config/compiler/vacpp.hpp index e5b69711..5ae9c285 100644 --- a/include/boost/config/compiler/vacpp.hpp +++ b/include/boost/config/compiler/vacpp.hpp @@ -91,6 +91,7 @@ #define BOOST_NO_TEMPLATE_ALIASES #define BOOST_NO_UNICODE_LITERALS #define BOOST_NO_VARIADIC_TEMPLATES +#define BOOST_NO_VARIADIC_MACROS diff --git a/include/boost/config/compiler/visualc.hpp b/include/boost/config/compiler/visualc.hpp index a862570f..6755287d 100644 --- a/include/boost/config/compiler/visualc.hpp +++ b/include/boost/config/compiler/visualc.hpp @@ -81,6 +81,8 @@ # define BOOST_NO_SWPRINTF // Our extern template tests also fail for this compiler: # define BOOST_NO_EXTERN_TEMPLATE +// Variadic macros do not exist for VC7.1 and lower +# define BOOST_NO_VARIADIC_MACROS #endif #if defined(UNDER_CE) diff --git a/test/all/Jamfile.v2 b/test/all/Jamfile.v2 index 01e90656..483bf98f 100644 --- a/test/all/Jamfile.v2 +++ b/test/all/Jamfile.v2 @@ -1,7 +1,7 @@ # # Regression test Jamfile for boost configuration setup. # *** DO NOT EDIT THIS FILE BY HAND *** -# This file was automatically generated on Fri Jun 04 12:51:35 2010 +# This file was automatically generated on Tue Aug 17 09:59:01 2010 # by libs/config/tools/generate.cpp # Copyright John Maddock. # Use, modification and distribution are subject to the @@ -511,6 +511,9 @@ test-suite "BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE" : test-suite "BOOST_NO_USING_TEMPLATE" : [ run ../no_using_template_pass.cpp ] [ compile-fail ../no_using_template_fail.cpp ] ; +test-suite "BOOST_NO_VARIADIC_MACROS" : +[ run ../no_variadic_macros_pass.cpp ] +[ compile-fail ../no_variadic_macros_fail.cpp ] ; test-suite "BOOST_NO_VARIADIC_TEMPLATES" : [ run ../no_variadic_templates_pass.cpp ] [ compile-fail ../no_variadic_templates_fail.cpp ] ; diff --git a/test/boost_no_variadic_macros.ipp b/test/boost_no_variadic_macros.ipp new file mode 100644 index 00000000..0382c21a --- /dev/null +++ b/test/boost_no_variadic_macros.ipp @@ -0,0 +1,62 @@ +// Copyright (C) 2010 Edward Diener +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org/libs/config for most recent version. + +// MACRO: BOOST_NO_VARIADIC_MACROS +// TITLE: C++0x variadic macros unavailable +// DESCRIPTION: The compiler does not support C++0x variadic macros + +// This is a simple test + +#define TEST_VARIADIC_MACRO_SIMPLE(avalue,...) __VA_ARGS__ + +/* + + This is a more complicated test, which Steve Watanabe graciously + supplied, when I asked if it were possible to strip the parantheses + from a macro argument. I have changed the names somewhat to prevent + any common clashes with other macros in the config testing suite + by prepending to each macro name TEST_VARIADIC_MACRO_. + + You may find this test overdone and may want to remove it. + +*/ + +#define TEST_VARIADIC_MACRO_CAT(x, y) TEST_VARIADIC_MACRO_CAT_I(x, y) +#define TEST_VARIADIC_MACRO_CAT_I(x, y) x ## y + +#define TEST_VARIADIC_MACRO_APPLY(macro, args) TEST_VARIADIC_MACRO_APPLY_I(macro, args) +#define TEST_VARIADIC_MACRO_APPLY_I(macro, args) macro args + +#define TEST_VARIADIC_MACRO_STRIP_PARENS(x) TEST_VARIADIC_MACRO_EVAL((TEST_VARIADIC_MACRO_STRIP_PARENS_I x), x) +#define TEST_VARIADIC_MACRO_STRIP_PARENS_I(...) 1,1 + +#define TEST_VARIADIC_MACRO_EVAL(test, x) TEST_VARIADIC_MACRO_EVAL_I(test, x) +#define TEST_VARIADIC_MACRO_EVAL_I(test, x) TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS(TEST_VARIADIC_MACRO_TEST_ARITY test, x) + +#define TEST_VARIADIC_MACRO_TEST_ARITY(...) TEST_VARIADIC_MACRO_APPLY(TEST_VARIADIC_MACRO_TEST_ARITY_I, (__VA_ARGS__, 2, 1)) +#define TEST_VARIADIC_MACRO_TEST_ARITY_I(a,b,c,...) c + +#define TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS(cond, x) TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS_I(cond, x) +#define TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS_I(cond, x) TEST_VARIADIC_MACRO_CAT(TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS_, cond)(x) + +#define TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS_1(x) x +#define TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS_2(x) TEST_VARIADIC_MACRO_APPLY(TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS_2_I, x) +#define TEST_VARIADIC_MACRO_MAYBE_STRIP_PARENS_2_I(...) __VA_ARGS__ + +namespace boost_no_variadic_macros { + +template struct test_variadic_macro_class {}; + +int test() +{ + + int x = TEST_VARIADIC_MACRO_STRIP_PARENS(3); + + return 0; +} + +} diff --git a/test/config_info.cpp b/test/config_info.cpp index a05586d4..cf62f529 100644 --- a/test/config_info.cpp +++ b/test/config_info.cpp @@ -1066,6 +1066,7 @@ void print_boost_macros() PRINT_MACRO(BOOST_NO_UNREACHABLE_RETURN_DETECTION); PRINT_MACRO(BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE); PRINT_MACRO(BOOST_NO_USING_TEMPLATE); + PRINT_MACRO(BOOST_NO_VARIADIC_MACROS); PRINT_MACRO(BOOST_NO_VARIADIC_TEMPLATES); PRINT_MACRO(BOOST_NO_VOID_RETURNS); @@ -1084,6 +1085,7 @@ void print_boost_macros() + // END GENERATED BLOCK PRINT_MACRO(BOOST_INTEL); diff --git a/test/config_test.cpp b/test/config_test.cpp index 22352565..fdce11dd 100644 --- a/test/config_test.cpp +++ b/test/config_test.cpp @@ -1,4 +1,4 @@ -// This file was automatically generated on Fri Jun 04 12:51:35 2010 +// This file was automatically generated on Tue Aug 17 09:59:01 2010 // by libs/config/tools/generate.cpp // Copyright John Maddock 2002-4. // Use, modification and distribution are subject to the @@ -582,6 +582,11 @@ namespace boost_no_using_declaration_overloads_from_typename_base = empty_boost; #else namespace boost_no_using_template = empty_boost; #endif +#ifndef BOOST_NO_VARIADIC_MACROS +#include "boost_no_variadic_macros.ipp" +#else +namespace boost_no_variadic_macros = empty_boost; +#endif #ifndef BOOST_NO_VARIADIC_TEMPLATES #include "boost_no_variadic_templates.ipp" #else @@ -1671,6 +1676,11 @@ int main( int, char *[] ) std::cerr << "Failed test for BOOST_NO_USING_TEMPLATE at: " << __FILE__ << ":" << __LINE__ << std::endl; ++error_count; } + if(0 != boost_no_variadic_macros::test()) + { + std::cerr << "Failed test for BOOST_NO_VARIADIC_MACROS at: " << __FILE__ << ":" << __LINE__ << std::endl; + ++error_count; + } if(0 != boost_no_variadic_templates::test()) { std::cerr << "Failed test for BOOST_NO_VARIADIC_TEMPLATES at: " << __FILE__ << ":" << __LINE__ << std::endl; diff --git a/test/no_variadic_macros_fail.cpp b/test/no_variadic_macros_fail.cpp new file mode 100644 index 00000000..e1195469 --- /dev/null +++ b/test/no_variadic_macros_fail.cpp @@ -0,0 +1,37 @@ +// This file was automatically generated on Tue Aug 17 09:59:01 2010 +// by libs/config/tools/generate.cpp +// Copyright John Maddock 2002-4. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org/libs/config for the most recent version.// +// Revision $Id: generate.cpp 49281 2008-10-11 15:40:44Z johnmaddock $ +// + + +// Test file for macro BOOST_NO_VARIADIC_MACROS +// This file should not compile, if it does then +// BOOST_NO_VARIADIC_MACROS should not be defined. +// See file boost_no_variadic_macros.ipp for details + +// Must not have BOOST_ASSERT_CONFIG set; it defeats +// the objective of this file: +#ifdef BOOST_ASSERT_CONFIG +# undef BOOST_ASSERT_CONFIG +#endif + +#include +#include "test.hpp" + +#ifdef BOOST_NO_VARIADIC_MACROS +#include "boost_no_variadic_macros.ipp" +#else +#error "this file should not compile" +#endif + +int main( int, char *[] ) +{ + return boost_no_variadic_macros::test(); +} + diff --git a/test/no_variadic_macros_pass.cpp b/test/no_variadic_macros_pass.cpp new file mode 100644 index 00000000..7475c4fa --- /dev/null +++ b/test/no_variadic_macros_pass.cpp @@ -0,0 +1,37 @@ +// This file was automatically generated on Tue Aug 17 09:59:01 2010 +// by libs/config/tools/generate.cpp +// Copyright John Maddock 2002-4. +// Use, modification and distribution are subject to the +// Boost Software License, Version 1.0. (See accompanying file +// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) + +// See http://www.boost.org/libs/config for the most recent version.// +// Revision $Id: generate.cpp 49281 2008-10-11 15:40:44Z johnmaddock $ +// + + +// Test file for macro BOOST_NO_VARIADIC_MACROS +// This file should compile, if it does not then +// BOOST_NO_VARIADIC_MACROS should be defined. +// See file boost_no_variadic_macros.ipp for details + +// Must not have BOOST_ASSERT_CONFIG set; it defeats +// the objective of this file: +#ifdef BOOST_ASSERT_CONFIG +# undef BOOST_ASSERT_CONFIG +#endif + +#include +#include "test.hpp" + +#ifndef BOOST_NO_VARIADIC_MACROS +#include "boost_no_variadic_macros.ipp" +#else +namespace boost_no_variadic_macros = empty_boost; +#endif + +int main( int, char *[] ) +{ + return boost_no_variadic_macros::test(); +} +