#line 635 "/home/travis/build/felix-lang/felix/src/packages/stl.fdoc"
  
  
  class Stl_Deque[t]
  {
      requires Cxx_headers::deque;
      type stl_deque = "::std::deque<?1>";
      fun create : unit -> stl_deque = "(FLX_GXX_PARSER_HACK std::deque<?1>())";
      fun create : int * t -> stl_deque= "(FLX_GXX_PARSER_HACK std::deque<?1>($1,$2))";
      fun create[i] : i * i -> stl_deque = "(FLX_GXX_PARSER_HACK std::deque<?1>($1,$2))";
      type stl_deque_iterator = "::std::deque<?1>::iterator";
      type stl_deque_reverse_iterator = "::std::deque<?1>::reverse_iterator";
      proc insert: stl_deque * stl_deque_iterator *  t  = "$1.insert($2,$3);";
      proc push_front : stl_deque *  t  = "$1.push_front($2);";
      proc push_back : stl_deque *  t  = "$1.push_back($2);";
      proc pop_front : stl_deque = "$1.pop_back();";
      fun front : stl_deque -> t = "$1.front()";
      fun front : stl_deque -> t = "$1.front()";
      fun subscript : stl_deque * int -> t = "$1.at($2)";
  // Stl_Deque
    instance Eq[stl_deque] {
      fun == : stl_deque * stl_deque -> bool = "$1==$2";
    }
    instance Container[stl_deque,t] {
      fun len: stl_deque -> size = "$1.size()";
      fun empty: stl_deque -> bool = "$1.empty()";
    }
    instance Sequence[stl_deque,stl_deque_iterator,t] {
      fun begin : stl_deque-> stl_deque_iterator= "$1.begin()";
      fun end : stl_deque-> stl_deque_iterator= "$1.end()";
      proc erase : stl_deque * stl_deque_iterator = "$1.erase($1);";
      proc erase_between : stl_deque * stl_deque_iterator * stl_deque_iterator = "$1.erase($1,$2);";
      proc clear : stl_deque = "$1.clear();";
    }
    instance Reversible_Sequence[stl_deque,stl_deque_iterator,stl_deque_reverse_iterator,t] {
      fun rbegin : stl_deque-> stl_deque_reverse_iterator= "$1.rbegin()";
      fun rend : stl_deque-> stl_deque_reverse_iterator= "$1.rend()";
    }
  
  // Stl_Deque iterator
    instance Eq[stl_deque_iterator] {
      fun == : stl_deque_iterator * stl_deque_iterator -> bool = "$1==$2";
    }
    instance Tord[stl_deque_iterator] {
      fun < : stl_deque_iterator * stl_deque_iterator -> bool = "$1<$2";
    }
    instance Iterator[stl_deque_iterator,t] {
      fun deref : stl_deque_iterator ->  t  = "*(#0*)(void*)&*$1";
    }
    instance Forward[stl_deque_iterator] {
      fun succ: stl_deque_iterator -> stl_deque_iterator = "$1+1";
      proc pre_incr : &stl_deque_iterator = "++*$1;";
      proc post_incr : &stl_deque_iterator = "++*$1;";
    }
    instance Forward_iterator[stl_deque_iterator,t] {}
    instance Bidirectional[stl_deque_iterator] {
      fun pred: stl_deque_iterator -> stl_deque_iterator = "$1-1;";
      proc pre_decr : &stl_deque_iterator = "--*$1;";
      proc post_decr : &stl_deque_iterator = "--*$1;";
    }
    instance Bidirectional_iterator[stl_deque_iterator,t] {}
  
  // Stl_Deque reverse iterator
    instance Eq[stl_deque_reverse_iterator] {
      fun == : stl_deque_reverse_iterator * stl_deque_reverse_iterator -> bool = "$1==$2";
    }
    instance Tord[stl_deque_reverse_iterator] {
      fun < : stl_deque_reverse_iterator * stl_deque_reverse_iterator -> bool = "$1<$2";
    }
    instance Iterator[stl_deque_reverse_iterator,t] {
      fun deref : stl_deque_reverse_iterator ->  t  = "*(#0*)(void*)&*$1";
    }
    instance Forward[stl_deque_reverse_iterator] {
      fun succ: stl_deque_reverse_iterator -> stl_deque_reverse_iterator = "$1+1";
      proc pre_incr : &stl_deque_reverse_iterator = "++*$1;";
      proc post_incr : &stl_deque_reverse_iterator = "++*$1;";
    }
    instance Forward_iterator[stl_deque_reverse_iterator,t] {}
    instance Bidirectional[stl_deque_reverse_iterator] {
      fun pred: stl_deque_reverse_iterator -> stl_deque_reverse_iterator = "$1-1;";
      proc pre_decr : &stl_deque_reverse_iterator = "--*$1;";
      proc post_decr : &stl_deque_reverse_iterator = "--*$1;";
    }
    instance Bidirectional_iterator[stl_deque_reverse_iterator,t] {}
  
  }
  
  open Stl_Deque;
  open[t] Reversible_Sequence[
    Stl_Deque::stl_deque[t],
    Stl_Deque::stl_deque_iterator[t],
    Stl:Stl_Deque::stl_deque_reverse_iterator[t],t];
  open[t] Bidirectional_iterator[Stl_Deque::stl_deque_iterator[t],t];
  open[t] Bidirectional_iterator[Stl_Deque::stl_deque_reverse_iterator[t],t];