Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
karlnapf committed Mar 29, 2019
1 parent 7f1f6b8 commit f6afbd1
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
11 changes: 10 additions & 1 deletion src/shogun/base/SGObject.cpp
Expand Up @@ -1119,4 +1119,13 @@ std::string CSGObject::string_enum_reverse_lookup(
return p.second == enum_value;
});
return enum_map_it->first;
}
}

namespace shogun
{
template <class T>
void test()
{
T* a;

This comment has been minimized.

Copy link
@karlnapf

karlnapf Mar 29, 2019

Author Owner

does make a call that depends on another include ...

}
}
4 changes: 4 additions & 0 deletions src/shogun/base/SGObject.h
Expand Up @@ -53,6 +53,9 @@ template <class T> class SGStringList;

using stringToEnumMapType = std::unordered_map<std::string, std::unordered_map<std::string, machine_int_t>>;

template <class T>
SG_FORCED_INLINE void test();

/*******************************************************************************
* define reference counter macros
******************************************************************************/
Expand Down Expand Up @@ -350,6 +353,7 @@ class CSGObject
template <typename T, typename std::enable_if_t<!is_string<T>::value>* = nullptr>
void put(const Tag<T>& _tag, const T& value) noexcept(false)
{
test<T>();
if (has_parameter(_tag))
{
auto parameter_value = get_parameter(_tag).get_value();
Expand Down

0 comments on commit f6afbd1

Please sign in to comment.