Boost logo

Boost :

Subject: Re: [boost] [Polygon] What does this error mean?
From: Stewart, Robert (Robert.Stewart_at_[hidden])
Date: 2009-09-03 15:34:50

Simonson, Lucanus J
> Stewart, Robert wrote:
> >
> > Concept checking would help immensely -- and was what I thought of
> > immediately upon seeing Lucanus' reply to your initial query --
> > because it would have indicated that std::pair<int,int> was not an
> > interval type. The documentation would then be able to direct you
> > to the traits specializations needed to satisfy the failed concept.
> > That is so much more helpful than obscure diagnostics from deep
> > within the library.
> If the rectangle concept applied a concept check on the
> interval_type defined in its traits and we checked the
> rectangle concept at the interface Phil originally called we
> would indeed get the error sooner and it could provide a
> better description of what was wrong.
> I think that it might be handy to provide some concept
> compile time checks that the user can use to verify that
> their traits are setup correctly. It might be overkill to
> perform concept checking on every interface, however. A
> simple check is to call the few free functions that directly
> access the traits. If these succeed all other interfaces
> will be valid.

Each public API that accepts an Interval should assert that the type meets the interval concept.

Rob Stewart robert.stewart_at_[hidden]
Software Engineer, Core Software using std::disclaimer;
Susquehanna International Group, LLP

IMPORTANT: The information contained in this email and/or its attachments is confidential. If you are not the intended recipient, please notify the sender immediately by reply and immediately delete this message and all its attachments. Any review, use, reproduction, disclosure or dissemination of this message or any attachment by an unintended recipient is strictly prohibited. Neither this message nor any attachment is intended as or should be construed as an offer, solicitation or recommendation to buy or sell any security or other financial instrument. Neither the sender, his or her employer nor any of their respective affiliates makes any warranties as to the completeness or accuracy of any of the information contained herein or that this message or any of its attachments is free of viruses.

Boost list run by bdawes at, gregod at, cpdaniel at, john at