Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.std.c++ > #490

Re: Container adaptor - missing container support operation

From Jason McKesson<jmckesson@gmail.com>
Newsgroups comp.std.c++
Subject Re: Container adaptor - missing container support operation
Date 2012-04-25 13:56 -0700
Organization http://groups.google.com
Message-ID <30470639.1126.1335304685758.JavaMail.geo-discussion-forums@ynid15> (permalink)
References <60068140-4f4a-434e-af9d-d6391c284fb8@g6g2000pbq.googlegroups.com>

Show all headers | View raw


On Tuesday, April 24, 2012 11:03:54 AM UTC-7, Akira Takahashi wrote:
>  Hi,
>
>  I read N3337's Container adaptors specification.
>  I think missing support operation : emplace_back().
>
>  23.6.3.1 queue definition
>  Any sequence container supporting operations front(), back(),
>  push_back() and pop_front() can be used to instantiate queue.
>
>  =>  add emplace_back().
>
>
>  23.6.4 Class template priority_queue
>  Any sequence container with random access iterator and supporting
>  operations front(), push_back() and pop_back() can be used to
>  instantiate priority_queue.
>
>  =>  add emplace_back().
>
>
>  23.6.5 Class template stack
>  Any sequence container supporting operations back(), push_back() and
>  pop_back() can be used to instantiate stack.
>
>  =>  add emplace_back().
>
>
>  Regards,
>  Akira
>
>

All of those containers have "emplace" functions, which does the same thing. You can only push into one place on the adapters, so "_back" is meaningless.


-- 
[ comp.std.c++ is moderated.  To submit articles, try posting with your ]
[ newsreader.  If that fails, use mailto:std-cpp-submit@vandevoorde.com ]
[              --- Please see the FAQ before posting. ---               ]
[ FAQ: http://www.comeaucomputing.com/csc/faq.html                      ]

Back to comp.std.c++ | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Container adaptor - missing container support operation Akira Takahashi <faithandbrave@gmail.com> - 2012-04-24 11:03 -0700
  Re: Container adaptor - missing container support operation Daniel Krügler<daniel.kruegler@googlemail.com> - 2012-04-25 13:56 -0700
  Re: Container adaptor - missing container support operation Jason McKesson<jmckesson@gmail.com> - 2012-04-25 13:56 -0700
    Re: Container adaptor - missing container support operation Akira Takahashi<faithandbrave@gmail.com> - 2012-04-26 11:07 -0700
  Re: Container adaptor - missing container support operation "Nevin \":-]\" Liber" <nevin@eviloverlord.com> - 2012-04-25 15:44 -0700
    Re: Container adaptor - missing container support operation Jason McKesson<jmckesson@gmail.com> - 2012-04-26 11:07 -0700
      Re: Container adaptor - missing container support operation Akira Takahashi <faithandbrave@gmail.com> - 2012-04-27 11:12 -0700

csiph-web