BWAPI
|
00001 // Copyright (c) 2005 Stanford University (USA). 00002 // All rights reserved. 00003 // 00004 // This file is part of CGAL (www.cgal.org); you can redistribute it and/or 00005 // modify it under the terms of the GNU Lesser General Public License as 00006 // published by the Free Software Foundation; version 2.1 of the License. 00007 // See the file LICENSE.LGPL distributed with CGAL. 00008 // 00009 // Licensees holding a valid commercial license may use this file in 00010 // accordance with the commercial license agreement provided with the software. 00011 // 00012 // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 00013 // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 00014 // 00015 // $URL: svn+ssh://scm.gforge.inria.fr/svn/cgal/branches/CGAL-3.5-branch/Kinetic_data_structures/include/CGAL/Polynomial/internal/macros.h $ 00016 // $Id: macros.h 40828 2007-11-07 21:35:42Z ameyer $ 00017 // 00018 // 00019 // Author(s) : Daniel Russel <drussel@alumni.princeton.edu> 00020 00021 #ifndef CGAL_POLYNOMIAL_INTERNAL_MACROS_H 00022 #define CGAL_POLYNOMIAL_INTERNAL_MACROS_H 00023 00024 #include <CGAL/Polynomial/internal/config.h> 00025 00026 #ifdef CGAL_POLYNOMIAL_USE_CGAL 00027 /* 00028 When CGAL is present 00029 */ 00030 #include <CGAL/basic.h> 00031 00032 #define CGAL_POLYNOMIAL_BEGIN_NAMESPACE CGAL_BEGIN_NAMESPACE \ 00033 namespace POLYNOMIAL \ 00034 { \ 00035 00036 #define CGAL_POLYNOMIAL_END_NAMESPACE } \ 00037 CGAL_END_NAMESPACE 00038 00039 #define CGAL_POLYNOMIAL_NS CGAL::POLYNOMIAL 00040 #define CGAL_Polynomial_assertion(x) CGAL_assertion(x) 00041 #define CGAL_Polynomial_assertion_code(x) CGAL_assertion_code(x) 00042 #define CGAL_Polynomial_precondition(x) CGAL_precondition(x) 00043 #define CGAL_Polynomial_precondition_code(x) CGAL_precondition_code(x) 00044 #define CGAL_Polynomial_postcondition(x) CGAL_postcondition(x) 00045 #ifdef CGAL_POLYNOMIAL_CHECK_EXPENSIVE 00046 #define CGAL_Polynomial_expensive_precondition(x) CGAL_expensive_precondition(x) 00047 #define CGAL_Polynomial_expensive_assertion(x) CGAL_expensive_assertion(x) 00048 #define CGAL_Polynomial_expensive_postcondition(x) CGAL_expensive_postcondition(x) 00049 #else 00050 #define CGAL_Polynomial_expensive_precondition(x) 00051 #define CGAL_Polynomial_expensive_assertion(x) 00052 #define CGAL_Polynomial_expensive_postcondition(x) 00053 #endif 00054 #define CGAL_Polynomial_exactness_assertion(x) CGAL_exactness_assertion(x) 00055 #define CGAL_Polynomial_exactness_postcondition(x) CGAL_exactness_postcondition(x) 00056 #define CGAL_Polynomial_exactness_precondition(x) CGAL_exactness_precondition(x) 00057 00058 #else 00059 /* 00060 When no CGAL is present 00061 */ 00062 00063 #define CGAL_POLYNOMIAL_BEGIN_NAMESPACE \ 00064 namespace Polynomial \ 00065 { \ 00066 00067 #define CGAL_POLYNOMIAL_END_NAMESPACE } 00068 00069 #define POLYNOMIAL_NS Polynomial 00070 00071 #include <cassert> 00072 00073 #define CGAL_Polynomial_assertion(x) assert(x) 00074 // This does not work 00075 #define CGAL_Polynomial_assertion_code(x) x 00076 #define CGAL_Polynomial_precondition(x) assert(x) 00077 #define CGAL_Polynomial_postcondition(x) assert(x) 00078 #define CGAL_Polynomial_expensive_precondition(x) 00079 #define CGAL_Polynomial_expensive_assertion(x) 00080 #define CGAL_Polynomial_expensive_postcondition(x) 00081 #define CGAL_Polynomial_exactness_postcondition(x) 00082 #define CGAL_Polynomial_exactness_precondition(x) 00083 #endif 00084 00085 #define CGAL_POLYNOMIAL_BEGIN_INTERNAL_NAMESPACE CGAL_POLYNOMIAL_BEGIN_NAMESPACE \ 00086 namespace internal \ 00087 { \ 00088 00089 #define CGAL_POLYNOMIAL_END_INTERNAL_NAMESPACE } \ 00090 CGAL_POLYNOMIAL_END_NAMESPACE 00091 #endif