boostorg / boostorg/parameter

Named template parameters are completely broken in Boost 1.71

Open
#91 7 comments 2 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
16
Forks
42
PR merge metrics
No merged PRs in 30d

Description

Since Boost 1.71 following code fails to compile on VS 2017 - default type is chosen instead of passed one and static assert fires.

```
#include
#include

BOOST_PARAMETER_TEMPLATE_KEYWORD(type_param)
BOOST_PARAMETER_TEMPLATE_KEYWORD(another_type_param)

class A {};

class B {};

class C {};

template
class CheckParams {
public:
typedef typename boost::parameter::parameters<
boost::parameter::optional
>::bind::type args;
typedef typename boost::parameter::value_type::type basic_shapes_policy;

CheckParams() {
static_assert(std::is_same::value, "");
}
};

void test() {
CheckParams<
another_type_param,
type_param
> instance;
}
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.