Topic: [c++std-core-27198] An implementation of
Author: Andrew Sutton <asutton.list@gmail.com>
Date: Thu, 5 Mar 2015 20:50:00 -0500
Raw View
>> template<typename ForwardIterator>
>> ForwardIterator next(ForwardIterator);
>>
>> but that's still true if it's rewritten like this:
>>
>> ForwardIterator next(ForwardIterator);
>
>
> That's not what I'm objecting to; I'm objecting to "auto" specifically. But
> since you mention it, this version definitely conveys less information than
> the previous one: it obscures the critical fact that 'next' is a function
> template.
Out of curiosity, why is next's template-ness a critical fact?
I've been writing a fair amount of C lately (and sadly). Many of the
functions I use turn out to be macros. I don't consider that to be a
critical fact. And when I'm writing C++, I generally don't care that
something I call is a template, only that there's an overload that
matches the arguments I call it with.
I've heard this argument before. I've yet to hear a good answer.
Andrew
--
---
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-discussion+unsubscribe@isocpp.org.
To post to this group, send email to std-discussion@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-discussion/.
.
Author: Nevin Liber <nevin@eviloverlord.com>
Date: Thu, 5 Mar 2015 20:09:22 -0600
Raw View
--001a113a60ecaa522a0510952e0a
Content-Type: text/plain; charset=UTF-8
On 5 March 2015 at 19:50, Andrew Sutton <asutton.list@gmail.com> wrote:
> Out of curiosity, why is next's template-ness a critical fact?
>
> I've been writing a fair amount of C lately (and sadly). Many of the
> functions I use turn out to be macros. I don't consider that to be a
> critical fact. And when I'm writing C++, I generally don't care that
> something I call is a template, only that there's an overload that
> matches the arguments I call it with.
>
> I've heard this argument before. I've yet to hear a good answer.
>
The two (what I consider to be very minor) concerns I have:
1. Does the definition belong in a header for correctness?
2. Unintended code bloat, since every set of types produces a new
instantiation.
With the template syntax, you have a very visual way to point that out.
Both auto and concepts are not visually different than a concrete type.
(Well your IDE may be able to address this, but syntactically it isn't
visually different).
--
Nevin ":-)" Liber <mailto:nevin@eviloverlord.com> (847) 691-1404
--
---
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 email 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-proposals/.
--001a113a60ecaa522a0510952e0a
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
<div dir=3D"ltr">On 5 March 2015 at 19:50, Andrew Sutton <span dir=3D"ltr">=
<<a href=3D"mailto:asutton.list@gmail.com" target=3D"_blank">asutton.lis=
t@gmail.com</a>></span> wrote:<br><div class=3D"gmail_extra"><div class=
=3D"gmail_quote"><blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8=
ex;border-left:1px #ccc solid;padding-left:1ex">Out of curiosity, why is ne=
xt's template-ness a critical fact?<br>
<br>
I've been writing a fair amount of C lately (and sadly). Many of the<br=
>
functions I use turn out to be macros. I don't consider that to be a<br=
>
critical fact. And when I'm writing C++, I generally don't care tha=
t<br>
something I call is a template, only that there's an overload that<br>
matches the arguments I call it with.<br>
<br>
I've heard this argument before. I've yet to hear a good answer.<br=
></blockquote><div><br></div><div>The two (what I consider to be very minor=
) concerns I have:</div><div><br></div><div>1.=C2=A0 Does the definition be=
long in a header for correctness?</div><div><br></div><div>2.=C2=A0 Uninten=
ded code bloat, since every set of types produces a new instantiation.</div=
><div><br></div><div>With the template syntax, you have a very visual way t=
o point that out.=C2=A0 Both auto and concepts are not visually different t=
han a concrete type. =C2=A0(Well your IDE may be able to address this, but =
syntactically it isn't visually different).</div><div>--=C2=A0<br></div=
></div><div class=3D"gmail_signature">=C2=A0Nevin ":-)" Liber=C2=
=A0 <mailto:<a href=3D"mailto:nevin@eviloverlord.com" target=3D"_blank">=
nevin@eviloverlord.com</a>>=C2=A0 (847) 691-1404</div>
</div></div>
<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 <a href=3D"mailto:std-proposals+unsubscribe@isocpp.org">std-proposa=
ls+unsubscribe@isocpp.org</a>.<br />
To post to this group, send email to <a href=3D"mailto:std-proposals@isocpp=
..org">std-proposals@isocpp.org</a>.<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 />
--001a113a60ecaa522a0510952e0a--
.