Index: src/benchmark/hcube.cc
===================================================================
--- src/benchmark/hcube.cc	(revision 840)
+++ src/benchmark/hcube.cc	(revision 905)
@@ -67,8 +67,11 @@
     
     //  for(EdgeIt e(G);G.valid(e);G.next(e)) map[e]=P();
-    for(int i=0;i<dim*(1<<dim);i++)
+    Edge te;
+    for(int i=0;i<dim*(1<<dim);i++) {
+      te.setToId(((long long int)(i)*93505)%(dim*(1<<dim)));
       //    map[Edge(((long long int)(i)*2987)%(dim*(1<<dim)))]=P();
-      map[Edge(((long long int)(i)*93505)%(dim*(1<<dim)))]=P();
-  
+      map[te]=P();
+    }
+    
 //     for(int i=0;i<(1<<dim);i++) {
 //       int mul= (1<<(numOfZeros(i,dim)/4));
Index: src/hugo/list_graph.h
===================================================================
--- src/hugo/list_graph.h	(revision 904)
+++ src/hugo/list_graph.h	(revision 905)
@@ -77,5 +77,5 @@
     // Create map registries.
     CREATE_MAP_REGISTRIES;
-    /// Create node and edge maps.
+    // Create node and edge maps.
     CREATE_MAPS(ArrayMap);
 
@@ -322,6 +322,5 @@
       template <typename T> friend class EdgeMap;
 
-      //template <typename T> friend class SymListGraph::SymEdgeMap;      
-      //friend Edge SymListGraph::opposite(Edge) const;
+      friend class SymListGraph;
       
       friend class Node;
@@ -343,8 +342,4 @@
       bool operator!=(const Edge i) const {return n!=i.n;}
       bool operator<(const Edge i) const {return n<i.n;}
-      ///\bug This is a workaround until somebody tells me how to
-      ///make class \c SymListGraph::SymEdgeMap friend of Edge
-      int &idref() {return n;}
-      const int &idref() const {return n;} 
       //      ///Validity check
       //      operator bool() { return n!=-1; }
@@ -364,7 +359,4 @@
       EdgeIt(const ListGraph& _G, Edge e) : Edge(e), G(&_G) { }
       EdgeIt() : Edge() { }
-      ///\bug This is a workaround until somebody tells me how to
-      ///make class \c SymListGraph::SymEdgeMap friend of Edge
-      int &idref() {return n;}
       EdgeIt &operator++() {
 	if(G->edges[n].next_in!=-1) n=G->edges[n].next_in;
@@ -466,5 +458,5 @@
     {
       Edge f;
-      f.idref() = e.idref() - 2*(e.idref()%2) + 1;
+      f.n = e.n - 2*(e.n%2) + 1;
       return f;
     }
@@ -605,5 +597,5 @@
     /// The ID of the \ref INVALID node is -1.
     ///\return The ID of the node \c v. 
-    int id(Node v) const { return v.n; }
+    static int id(Node v) { return v.n; }
     /// Edge ID.
     
@@ -614,5 +606,5 @@
     /// The ID of the \ref INVALID edge is -1.
     ///\return The ID of the edge \c e. 
-    int id(Edge e) const { return -1; }
+    static int id(Edge e) { return -1; }
 
     /// Adds a new node to the graph.
@@ -684,5 +676,5 @@
     protected:
       int n;
-      friend int NodeSet::id(Node v) const; 
+      friend int NodeSet::id(Node v); 
       Node(int nn) {n=nn;}
     public:
@@ -709,15 +701,4 @@
 
     class Edge {
-      //friend class NodeSet;
-      //template <typename T> friend class EdgeMap;
-
-      //template <typename T> friend class SymNodeSet::SymEdgeMap;      
-      //friend Edge SymNodeSet::opposite(Edge) const;
-      
-      //      friend class Node;
-      //      friend class NodeIt;
-    protected:
-      //friend int NodeSet::id(Edge e) const;
-      //      Edge(int nn) {}
     public:
       Edge() { }
@@ -726,12 +707,7 @@
       bool operator!=(const Edge i) const {return false;}
       bool operator<(const Edge i) const {return false;}
-      ///\bug This is a workaround until somebody tells me how to
-      ///make class \c SymNodeSet::SymEdgeMap friend of Edge
-      //      int idref() {return -1;}
-      //      int idref() const {return -1;}
     };
     
     class EdgeIt : public Edge {
-      //friend class NodeSet;
     public:
       EdgeIt(const NodeSet& G) : Edge() { }
@@ -739,7 +715,4 @@
       EdgeIt (Invalid i) : Edge(i) { }
       EdgeIt() : Edge() { }
-      ///\bug This is a workaround until somebody tells me how to
-      ///make class \c SymNodeSet::SymEdgeMap friend of Edge
-      //      int idref() {return -1;}
       EdgeIt operator++() { return INVALID; }
     };
@@ -811,5 +784,4 @@
     class Node : public NodeGraphType::Node {
       friend class EdgeSet;
-      //      template <typename T> friend class NodeMap;
       
       friend class Edge;
@@ -820,5 +792,4 @@
     public:
       friend int EdgeSet::id(Node v) const; 
-      //      Node(int nn) {n=nn;}
     public:
       Node() : NodeGraphType::Node() {}
@@ -947,5 +918,5 @@
     /// The ID of the \ref INVALID edge is -1.
     ///\return The ID of the edge \c e. 
-    int id(Edge e) const { return e.n; }
+    static int id(Edge e) { return e.n; }
 
     /// Adds a new node to the graph.
@@ -1024,11 +995,4 @@
   public:
 
-//     void erase(Node nn) {
-//       int n=nn.n;
-//       int m;
-//       while((m=nodes[n].first_in)!=-1) eraseEdge(m);
-//       while((m=nodes[n].first_out)!=-1) eraseEdge(m);
-//     }
-    
     void erase(Edge e) { eraseEdge(e.n); }
 
@@ -1048,9 +1012,6 @@
       friend class Node;
       friend class NodeIt;
-    public:
-      ///\bug It should be at least protected
-      ///
+    protected:
       int n;
-    protected:
       friend int EdgeSet::id(Edge e) const;
 
@@ -1062,8 +1023,4 @@
       bool operator!=(const Edge i) const {return n!=i.n;}
       bool operator<(const Edge i) const {return n<i.n;}
-      ///\bug This is a workaround until somebody tells me how to
-      ///make class \c SymEdgeSet::SymEdgeMap friend of Edge
-      int &idref() {return n;}
-      const int &idref() const {return n;}
     };
     
@@ -1075,5 +1032,4 @@
     public:
       EdgeIt(const EdgeSet& _G) : Edge(), G(&_G) {
-	//      	typename NodeGraphType::Node m;
         NodeIt m;
 	for(G->first(m);
@@ -1092,7 +1048,4 @@
 	return *this;
       }
-       ///\bug This is a workaround until somebody tells me how to
-      ///make class \c SymEdgeSet::SymEdgeMap friend of Edge
-      int &idref() {return this->n;}
     };
     
Index: src/hugo/smart_graph.h
===================================================================
--- src/hugo/smart_graph.h	(revision 904)
+++ src/hugo/smart_graph.h	(revision 905)
@@ -218,6 +218,5 @@
       template <typename T> friend class EdgeMap;
 
-      //template <typename T> friend class SymSmartGraph::SymEdgeMap;      
-      //friend Edge SymSmartGraph::opposite(Edge) const;
+      friend class SymSmartGraph;
       
       friend class Node;
@@ -226,11 +225,8 @@
       int n;
       friend int SmartGraph::id(Edge e);
-
+      Edge(int nn) {n=nn;}
     public:
       /// An Edge with id \c n.
 
-      /// \bug It should be
-      /// obtained by a member function of the Graph.
-      Edge(int nn) {n=nn;}
       Edge() { }
       Edge (Invalid) { n=-1; }
@@ -238,10 +234,9 @@
       bool operator!=(const Edge i) const {return n!=i.n;}
       bool operator<(const Edge i) const {return n<i.n;}
-      ///\bug This is a workaround until somebody tells me how to
-      ///make class \c SymSmartGraph::SymEdgeMap friend of Edge
-      int &idref() {return n;}
-      const int &idref() const {return n;} 
 //       ///Validity check
 //       operator bool() { return n!=-1; }
+
+      ///Set the edge to that have ID \c ID.
+      void setToId(int id) { n=id; }
    };
     
@@ -254,7 +249,4 @@
       EdgeIt (Invalid i) : Edge(i) { }
       EdgeIt() : Edge() { }
-      ///\bug This is a workaround until somebody tells me how to
-      ///make class \c SymSmartGraph::SymEdgeMap friend of Edge
-      int &idref() {return n;}
       EdgeIt &operator++() { --n; return *this; }
 //       ///Validity check
@@ -343,5 +335,5 @@
     {
       Edge f;
-      f.idref() = e.idref() - 2*(e.idref()%2) + 1;
+      f.n = e.n - 2*(e.n%2) + 1;
       return f;
     }
