Topic: N3854 - Variable Templates For Type Traits
Author: "Vicente J. Botet Escriba" <vicente.botet@wanadoo.fr>
Date: Mon, 03 Feb 2014 06:27:10 +0100
Raw View
This is a multi-part message in MIME format.
--------------050107040009070404000800
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: quoted-printable
Le 03/02/14 05:44, Bengt Gustafsson a =C3=A9crit :
> Isn't that already made next to impossible by the new usings for the=20
> corresponding type_traits yielding a type, such as std::add_const_t?
>
> This sets the example, although to me it is really backwards to have=20
> to select between the ugly add_const_t and the worse add_const::type.=20
> After all template using and type_traits were introduced in the same=20
> standard version...
>
> This deed done, I guess the only way out is to work on a proposal for=20
> library versioning so that you can select which version of the library=20
> you want to use. That's however something completely different.
>
>
Hi,
I have some difficulties in seen how your post relates to mine. Could=20
you be more precise?
Vicente
P.S. Please don't top post.
> Den s=C3=B6ndagen den 26:e januari 2014 kl. 08:08:59 UTC+1 skrev Vicente =
J.=20
> Botet Escriba:
>
> Hi,
>
> In
> https://groups.google.com/a/isocpp.org/forum/#!topic/std-proposals/QO=
YLLJjH98k
> <https://groups.google.com/a/isocpp.org/forum/#%21topic/std-proposals=
/QOYLLJjH98k>
> I posted a similar proposal.
>
> Most of the proposed variable templates could be considered as
> Concepts Lite constraints. Have you considered to use CamelCase
> instead of the suffix _v?
>
> Instead of
>
> template <class T, class... Args> constexpr bool is_constructible_v
> =3D is_constructible<T, Args...>::value;
>
>
> include
>
> template <class T, class... Args> constexpr bool Constructible
> =3D is_constructible<T, Args...>::value;
>
>
> In this way we could
>
> template< CopyConstructible T > bool f( T v );
>
>
--=20
---=20
You received this message because you are subscribed to the Google Groups "=
ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposa=
ls/.
--------------050107040009070404000800
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
<html>
<head>
<meta content=3D"text/html; charset=3DUTF-8" http-equiv=3D"Content-Type=
">
</head>
<body bgcolor=3D"#FFFFFF" text=3D"#000000">
<div class=3D"moz-cite-prefix">Le 03/02/14 05:44, Bengt Gustafsson a
=C3=A9crit=C2=A0:<br>
</div>
<blockquote
cite=3D"mid:b7d0f240-c3e5-43a6-9975-820dff5017fb@isocpp.org"
type=3D"cite">
<div dir=3D"ltr">Isn't that already made next to impossible by the
new usings for the corresponding type_traits yielding a type,
such as std::add_const_t?=C2=A0
<div><br>
</div>
<div>This sets the example, although to me it is really
backwards to have to select between the ugly add_const_t and
the worse add_const::type. After all template using and
type_traits were introduced in the same standard version...</div>
<div><br>
</div>
<div>This deed done, I guess the only way out is to work on a
proposal for library versioning so that you can select which
version of the library you want to use. That's however
something completely different.</div>
<div><br>
<br>
</div>
</div>
</blockquote>
Hi,<br>
<br>
I have some difficulties in seen how your post relates to mine.
Could you be more precise?<br>
<br>
Vicente<br>
<br>
P.S. Please don't top post. <br>
<br>
<blockquote
cite=3D"mid:b7d0f240-c3e5-43a6-9975-820dff5017fb@isocpp.org"
type=3D"cite">
<div dir=3D"ltr">
<div>Den s=C3=B6ndagen den 26:e januari 2014 kl. 08:08:59 UTC+1 skr=
ev
Vicente J. Botet Escriba:
<blockquote class=3D"gmail_quote" style=3D"margin: 0;margin-left:
0.8ex;border-left: 1px #ccc solid;padding-left: 1ex;">
<div bgcolor=3D"#FFFFFF" text=3D"#000000"> Hi,<br>
<br>
In <a moz-do-not-send=3D"true"
href=3D"https://groups.google.com/a/isocpp.org/forum/#%21topic/std-proposal=
s/QOYLLJjH98k"
target=3D"_blank"
onmousedown=3D"this.href=3D'https://groups.google.com/a/iso=
cpp.org/forum/#!topic/std-proposals/QOYLLJjH98k';return
true;"
onclick=3D"this.href=3D'https://groups.google.com/a/isocpp.=
org/forum/#!topic/std-proposals/QOYLLJjH98k';return
true;">https://groups.google.com/a/<wbr>isocpp.org/forum/#!=
topic/std-<wbr>proposals/QOYLLJjH98k</a>
I posted a similar proposal. <br>
<br>
Most of the proposed variable templates could be
considered as Concepts Lite constraints. Have you
considered to use CamelCase instead of the suffix _v?<br>
<br>
Instead of<br>
<br>
<pre>template <class T, class... Args> constexpr bool i=
s_constructible_v
=3D is_constructible<T, Args...>::value;</pre>
<br>
include<br>
<br>
<pre>template <class T, class... Args> constexpr bool C=
onstructible
=3D is_constructible<T, Args...>::value;</pre>
<br>
In this way we could <br>
<pre><tt><big><big><small><font style=3D"font-size:8pt" size=
=3D"1"><big>template< CopyConstructible T ></big></font><font style=
=3D"font-size:8pt" size=3D"1"><big> bool f( T v );</big></font>
</small></big></big></tt>
</pre>
</div>
</blockquote>
</div>
</div>
</blockquote>
<br>
</body>
</html>
<p></p>
-- <br />
<br />
--- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.<br />
To post to this group, send email to std-proposals@isocpp.org.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/">http://groups.google.com/a/isocpp.org/group/std-proposals/<=
/a>.<br />
--------------050107040009070404000800--
.