Topic: optional Rev.4 (N3672): What was the rationale to
Author: Kazutoshi Satoda <k_satoda@f2.dion.ne.jp>
Date: Wed, 01 May 2013 18:54:34 +0900
Raw View
From http://isocpp.org/files/papers/N3672.html
> Changes since R4C
> Removed all relational operators except operator== and operator<.
So, should we write !(opt == 123) instead of opt != 123 ? My immediate
feeling was, that's unreasonable.
What was the rationale for the removal?
I think the rationale should be written in the section about relational
operators to make the paper complete.
http://isocpp.org/files/papers/N3672.html#rationale.relops
--
k_satoda
--
---
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/?hl=en.
.
Author: DeadMG <wolfeinstein@gmail.com>
Date: Wed, 1 May 2013 03:53:10 -0700 (PDT)
Raw View
------=_Part_5057_24811159.1367405590237
Content-Type: text/plain; charset=ISO-8859-1
Basically, because no matter what you do with them, they produce
unintuitive surprising results, and the Committee could not agree on which
set of utter insanity it preferred, so it chose to simply drop them. In the
future, when we agree on which of the two horrific evils is insignificantly
lesser, they may be re-added. < and == were kept because they were
uncontroversial, no surprising downsides, and were necessary to keep
optional<T> valid in set/unordered_set and similar friends.
--
---
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/?hl=en.
------=_Part_5057_24811159.1367405590237
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Basically, because no matter what you do with them, they produce unintuitiv=
e surprising results, and the Committee could not agree on which set of utt=
er insanity it preferred, so it chose to simply drop them. In the future, w=
hen we agree on which of the two horrific evils is insignificantly lesser, =
they may be re-added. < and =3D=3D were kept because they were uncontrov=
ersial, no surprising downsides, and were necessary to keep optional<T&g=
t; valid in set/unordered_set and similar friends.
<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/?hl=3Den">http://groups.google.com/a/isocpp.org/group/std-pro=
posals/?hl=3Den</a>.<br />
<br />
<br />
------=_Part_5057_24811159.1367405590237--
.
Author: Marc <marc.glisse@gmail.com>
Date: Wed, 1 May 2013 04:50:01 -0700 (PDT)
Raw View
------=_Part_715_14004255.1367409001289
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Le mercredi 1 mai 2013 12:53:10 UTC+2, DeadMG a =E9crit :
>
> Basically, because no matter what you do with them, they produce=20
> unintuitive surprising results, and the Committee could not agree on whic=
h=20
> set of utter insanity it preferred, so it chose to simply drop them. In t=
he=20
> future, when we agree on which of the two horrific evils is insignificant=
ly=20
> lesser, they may be re-added. < and =3D=3D were kept because they were=20
> uncontroversial, no surprising downsides, and were necessary to keep=20
> optional<T> valid in set/unordered_set and similar friends.
For set, you need std::less, not operator<. I think there have already been=
=20
discussions since then saying that implementing optional<T>::operator< in=
=20
terms of less<T> is a bad idea, we can specialize less instead.
--=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/?hl=3Den.
------=_Part_715_14004255.1367409001289
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
Le mercredi 1 mai 2013 12:53:10 UTC+2, DeadMG a =E9crit :<blockquote c=
lass=3D"gmail_quote" style=3D"margin: 0;margin-left: 0.8ex;border-left: 1px=
#ccc solid;padding-left: 1ex;">Basically, because no matter what you do wi=
th them, they produce unintuitive surprising results, and the Committee cou=
ld not agree on which set of utter insanity it preferred, so it chose to si=
mply drop them. In the future, when we agree on which of the two horrific e=
vils is insignificantly lesser, they may be re-added. < and =3D=3D were =
kept because they were uncontroversial, no surprising downsides, and were n=
ecessary to keep optional<T> valid in set/unordered_set and similar f=
riends.</blockquote><div><br>For set, you need std::less, not operator<.=
I think there have already been discussions since then saying that impleme=
nting optional<T>::operator< in terms of less<T> is a =
bad idea, we can specialize less instead.<br></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 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/?hl=3Den">http://groups.google.com/a/isocpp.org/group/std-pro=
posals/?hl=3Den</a>.<br />
<br />
<br />
------=_Part_715_14004255.1367409001289--
.