src/test/graph_test.cc
changeset 515 a7eeb8af6b34
parent 504 6ef30329dd50
child 542 69bde1d90c04
     1.1 --- a/src/test/graph_test.cc	Mon May 03 14:43:49 2004 +0000
     1.2 +++ b/src/test/graph_test.cc	Mon May 03 17:06:38 2004 +0000
     1.3 @@ -108,11 +108,12 @@
     1.4    //NodeMap tests
     1.5    {
     1.6      Node k;
     1.7 -    typename Graph::NodeMap<int> m(G);
     1.8 -    typename Graph::NodeMap<int> const &cm = m;  //Const map
     1.9 -    typename Graph::NodeMap<int> mdef(G,12); //Inicialize with default value
    1.10 -    typename Graph::NodeMap<int> mm(cm);   //Copy
    1.11 -    typename Graph::NodeMap<double> dm(cm); //Copy from another type
    1.12 +    typename Graph::template NodeMap<int> m(G);
    1.13 +    typename Graph::template NodeMap<int> const &cm = m;  //Const map
    1.14 +    //Inicialize with default value
    1.15 +    typename Graph::template NodeMap<int> mdef(G,12);
    1.16 +    typename Graph::template NodeMap<int> mm(cm);   //Copy
    1.17 +    typename Graph::template NodeMap<double> dm(cm); //Copy from another type
    1.18      int v;
    1.19      v=m[k]; m[k]=v; m.set(k,v);
    1.20      v=cm[k];
    1.21 @@ -122,11 +123,12 @@
    1.22    }  
    1.23    { //bool NodeMap
    1.24      Node k;
    1.25 -    typename Graph::NodeMap<bool> m(G);
    1.26 -    typename Graph::NodeMap<bool> const &cm = m;  //Const map
    1.27 -    typename Graph::NodeMap<bool> mdef(G,12); //Inicialize with default value
    1.28 -    typename Graph::NodeMap<bool> mm(cm);   //Copy
    1.29 -    typename Graph::NodeMap<int> dm(cm); //Copy from another type
    1.30 +    typename Graph::template NodeMap<bool> m(G);
    1.31 +    typename Graph::template NodeMap<bool> const &cm = m;  //Const map
    1.32 +    //Inicialize with default value
    1.33 +    typename Graph::template NodeMap<bool> mdef(G,12);
    1.34 +    typename Graph::template NodeMap<bool> mm(cm);   //Copy
    1.35 +    typename Graph::template NodeMap<int> dm(cm); //Copy from another type
    1.36      bool v;
    1.37      v=m[k]; m[k]=v; m.set(k,v);
    1.38      v=cm[k];
    1.39 @@ -138,11 +140,12 @@
    1.40    //EdgeMap tests
    1.41    {
    1.42      Edge k;
    1.43 -    typename Graph::EdgeMap<int> m(G);
    1.44 -    typename Graph::EdgeMap<int> const &cm = m;  //Const map
    1.45 -    typename Graph::EdgeMap<int> mdef(G,12); //Inicialize with default value
    1.46 -    typename Graph::EdgeMap<int> mm(cm);   //Copy
    1.47 -    typename Graph::EdgeMap<double> dm(cm); //Copy from another type
    1.48 +    typename Graph::template EdgeMap<int> m(G);
    1.49 +    typename Graph::template EdgeMap<int> const &cm = m;  //Const map
    1.50 +    //Inicialize with default value
    1.51 +    typename Graph::template EdgeMap<int> mdef(G,12);
    1.52 +    typename Graph::template EdgeMap<int> mm(cm);   //Copy
    1.53 +    typename Graph::template EdgeMap<double> dm(cm); //Copy from another type
    1.54      int v;
    1.55      v=m[k]; m[k]=v; m.set(k,v);
    1.56      v=cm[k];
    1.57 @@ -152,11 +155,12 @@
    1.58    }  
    1.59    { //bool EdgeMap
    1.60      Edge k;
    1.61 -    typename Graph::EdgeMap<bool> m(G);
    1.62 -    typename Graph::EdgeMap<bool> const &cm = m;  //Const map
    1.63 -    typename Graph::EdgeMap<bool> mdef(G,12); //Inicialize with default value
    1.64 -    typename Graph::EdgeMap<bool> mm(cm);   //Copy
    1.65 -    typename Graph::EdgeMap<int> dm(cm); //Copy from another type
    1.66 +    typename Graph::template EdgeMap<bool> m(G);
    1.67 +    typename Graph::template EdgeMap<bool> const &cm = m;  //Const map
    1.68 +    //Inicialize with default value
    1.69 +    typename Graph::template EdgeMap<bool> mdef(G,12);
    1.70 +    typename Graph::template EdgeMap<bool> mm(cm);   //Copy
    1.71 +    typename Graph::template EdgeMap<int> dm(cm); //Copy from another type
    1.72      bool v;
    1.73      v=m[k]; m[k]=v; m.set(k,v);
    1.74      v=cm[k];