Boost logo

Boost :

From: Jonathan Turkanis (technews_at_[hidden])
Date: 2004-10-26 23:17:26


"Thorsten Ottosen" <nesotto_at_[hidden]> wrote in message
news:00ba01c4bbd5$a9d5dd50$0b40a8c0_at_nesottolap...
>

> | What am I doing wrong?
>
> nothing AFAICT. If I use como + dinkumware, then it works on that compiler
> too, so It might be a std-library issue.
>
> You could try to help the compiler a little:
>
>
> #include <boost/assign.hpp>
> #include <vector>
> #include <list>
> #include <string>
>
> int main()
> {
> using namespace std;
> using namespace boost::assign;
>
> typedef pair<string,string> pair_t;
> typedef list< pair_t > list_t;
>
> vector< list_t > v =
> list_of< list_t >(
> list_of<pair_t>( "hello", "goodbye" )
> ( "morning", "evening" )
> ( "cold", "hot" )
> )
> (
> list_of<pair_t>( "hello", "goodbye" )
> ( "morning", "evening" )
> ( "cold", "hot" )
> );
> }

Thanks.

>
> -Thorsten
>
> PS: do you mind if I steal your example for the article I'm writing?
>

Steal away!

Jonathan


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk