Skip to content

Instantly share code, notes, and snippets.

@adamjernst
Created March 13, 2012 15:41
Show Gist options
  • Save adamjernst/2029478 to your computer and use it in GitHub Desktop.
Save adamjernst/2029478 to your computer and use it in GitHub Desktop.
Errors from output of including boost::icl::interval_set
c++ -Wall -g -c PathComputation.cpp
In file included from PathComputation.cpp:9:
In file included from ./PathComputation.hpp:19:
In file included from ./DeletedPatterns.hpp:15:
In file included from /usr/local/include/boost/icl/interval_set.hpp:14:
In file included from /usr/local/include/boost/icl/interval_base_set.hpp:24:
In file included from /usr/local/include/boost/icl/associative_interval_container.hpp:12:
In file included from /usr/local/include/boost/icl/concept/comparable.hpp:12:
In file included from /usr/local/include/boost/icl/type_traits/is_icl_container.hpp:14:
In file included from /usr/local/include/boost/icl/type_traits/is_element_container.hpp:14:
In file included from /usr/local/include/boost/icl/type_traits/is_container.hpp:18:
In file included from /usr/local/include/boost/icl/type_traits/size_type_of.hpp:12:
In file included from /usr/local/include/boost/icl/type_traits/difference_type_of.hpp:12:
In file included from /usr/local/include/boost/type_traits/is_pointer.hpp:24:
In file included from /usr/local/include/boost/type_traits/is_member_pointer.hpp:28:
In file included from /usr/local/include/boost/type_traits/is_member_function_pointer.hpp:24:
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:38:11: error: declaration of anonymous class must be a definition
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:38:28: error: a non-type template parameter cannot have type 'class T'
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:39:38: error: expected unqualified-id
struct is_mem_fun_pointer_impl<R (T::*)() > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:39:39: error: expected expression
struct is_mem_fun_pointer_impl<R (T::*)() > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:41:11: error: declaration of anonymous class must be a definition
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:41:28: error: a non-type template parameter cannot have type 'class T'
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:42:38: error: expected unqualified-id
struct is_mem_fun_pointer_impl<R (T::*)( ...) > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:42:39: error: expected expression
struct is_mem_fun_pointer_impl<R (T::*)( ...) > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:42:42: error: expected expression
struct is_mem_fun_pointer_impl<R (T::*)( ...) > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:46:11: error: declaration of anonymous class must be a definition
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:46:28: error: a non-type template parameter cannot have type 'class T'
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:47:38: error: expected unqualified-id
struct is_mem_fun_pointer_impl<R (T::*)() const > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:47:39: error: expected expression
struct is_mem_fun_pointer_impl<R (T::*)() const > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:49:11: error: declaration of anonymous class must be a definition
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:49:28: error: a non-type template parameter cannot have type 'class T'
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:50:38: error: expected unqualified-id
struct is_mem_fun_pointer_impl<R (T::*)() volatile > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:50:39: error: expected expression
struct is_mem_fun_pointer_impl<R (T::*)() volatile > { BOOST_STATIC_CONSTANT(bool, value = true); };
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:52:11: error: declaration of anonymous class must be a definition
template <class R, class T >
^
/usr/local/include/boost/type_traits/detail/is_mem_fun_pointer_impl.hpp:52:28: error: a non-type template parameter cannot have type 'class T'
template <class R, class T >
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
make: *** [PathComputation.o] Error 1
@adamjernst
Copy link
Author

For what it's worth, turns out this resulted because I had a gross #define in a file that was included before the boost ICL include.

#define R 6378137.0 // Earth's radius in meters

Don't do that! First, it's not good practice; second, it conflicts with the class T template code in boost.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment