Free Trial

Safari Books Online is a digital library providing on-demand subscription access to thousands of learning resources.


  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • DownloadDownload
  • PrintPrint
Share this Page URL
Help

Chapter 6. Functors, Functor Classes, Fu... > Item 42: Make sure less<T> means ope...

Item 42: Make sure less<T> means operator<

As all Widget-savvy people are aware, Widgets have both a weight and a maximum speed:

class Widget {
public:
  ...

  size_t weight() const;
  size_t maxSpeed() const;

  ...
};


  

You are currently reading a PREVIEW of this book.

                                                                                        

Get instant access to over
$1 million worth of books and videos.

  

Start a Free Trial