Skip to content

Commit

Permalink
fix for: template argument for template template parameter must be a …
Browse files Browse the repository at this point in the history
…class template or type alias template
  • Loading branch information
btb committed Nov 23, 2014
1 parent 93a80e5 commit 2f9543f
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions common/include/valptridx.h
Original file line number Diff line number Diff line change
Expand Up @@ -103,22 +103,22 @@ class valptr_t : protected valbaseptridxutil_t<P, I>
valptr_t(vvalptr_t<Prc, I> &&) = delete;
valptr_t(std::nullptr_t) : p(nullptr) {}
template <template <I> class magic_constant>
valptr_t(valptridx_template_t<vvalptr_t, vvalidx_t, valptr_t, validx_t, const P, I, magic_constant> v) :
valptr_t(valptridx_template_t<vvalptr_t, vvalidx_t, valptr_t::template valptr_t, validx_t, const P, I, magic_constant> v) :
p(v)
{
}
template <template <I> class magic_constant>
valptr_t(valptridx_template_t<vvalptr_t, vvalidx_t, valptr_t, validx_t, Prc, I, magic_constant> v) :
valptr_t(valptridx_template_t<vvalptr_t, vvalidx_t, valptr_t::template valptr_t, validx_t, Prc, I, magic_constant> v) :
p(v)
{
}
template <template <I> class magic_constant>
valptr_t(valptridx_template_t<valptr_t, validx_t, vvalptr_t, vvalidx_t, const P, I, magic_constant> v) :
valptr_t(valptridx_template_t<valptr_t::template valptr_t, validx_t, vvalptr_t, vvalidx_t, const P, I, magic_constant> v) :
p(v)
{
}
template <template <I> class magic_constant>
valptr_t(valptridx_template_t<valptr_t, validx_t, vvalptr_t, vvalidx_t, Prc, I, magic_constant> v) :
valptr_t(valptridx_template_t<valptr_t::template valptr_t, validx_t, vvalptr_t, vvalidx_t, Prc, I, magic_constant> v) :
p(v)
{
}
Expand Down Expand Up @@ -410,22 +410,22 @@ class vvalptr_t : public valptr_t<P, I>
{
}
template <template <I> class magic_constant>
vvalptr_t(valptridx_template_t<vvalptr_t, vvalidx_t, valptr_t, validx_t, const P, I, magic_constant> v) :
vvalptr_t(valptridx_template_t<vvalptr_t::template vvalptr_t, vvalidx_t, valptr_t, validx_t, const P, I, magic_constant> v) :
base_t(v)
{
}
template <template <I> class magic_constant>
vvalptr_t(valptridx_template_t<vvalptr_t, vvalidx_t, valptr_t, validx_t, Prc, I, magic_constant> v) :
vvalptr_t(valptridx_template_t<vvalptr_t::template vvalptr_t, vvalidx_t, valptr_t, validx_t, Prc, I, magic_constant> v) :
base_t(v)
{
}
template <template <I> class magic_constant>
vvalptr_t(valptridx_template_t<valptr_t, validx_t, vvalptr_t, vvalidx_t, const P, I, magic_constant> v) :
vvalptr_t(valptridx_template_t<valptr_t, validx_t, vvalptr_t::template vvalptr_t, vvalidx_t, const P, I, magic_constant> v) :
base_t(check_null_pointer(v))
{
}
template <template <I> class magic_constant>
vvalptr_t(valptridx_template_t<valptr_t, validx_t, vvalptr_t, vvalidx_t, Prc, I, magic_constant> v) :
vvalptr_t(valptridx_template_t<valptr_t, validx_t, vvalptr_t::template vvalptr_t, vvalidx_t, Prc, I, magic_constant> v) :
base_t(check_null_pointer(v))
{
}
Expand Down

3 comments on commit 2f9543f

@vLKp
Copy link

@vLKp vLKp commented on 2f9543f Nov 30, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

NAK. This breaks building with x86_64-pc-linux-gnu-g++-4.9.

@vLKp
Copy link

@vLKp vLKp commented on 2f9543f Nov 30, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fortunately, the existing code breaks x86_64-pc-linux-gnu clang, so I can investigate alternate fixes. I have one in mind that should solve this and also work around a Visual Studio parser bug that fails on the same line.

@vLKp
Copy link

@vLKp vLKp commented on 2f9543f Dec 1, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commit 690dec3 provides an alternate solution that works in both x86_64-pc-linux-gnu clang and gcc.

Please sign in to comment.