Browse Source

Move depth() from DPF to RDPF

Ian Goldberg 1 year ago
parent
commit
64fa2cbc67
2 changed files with 4 additions and 5 deletions
  1. 1 5
      dpf.hpp
  2. 3 0
      rdpf.hpp

+ 1 - 5
dpf.hpp

@@ -42,15 +42,11 @@ struct DPF {
     DPFnode seed;
     // Which half of the DPF are we?
     bit_t whichhalf;
-    // correction words; the depth of the DPF is the length of this
-    // vector
+    // correction words
     std::vector<DPFnode> cw;
     // correction flag bits: the one for level i is bit i of this word
     value_t cfbits;
 
-    // The depth
-    inline nbits_t depth() const { return cw.size(); }
-
     // The seed
     inline node get_seed() const { return seed; }
 

+ 3 - 0
rdpf.hpp

@@ -52,6 +52,9 @@ struct RDPF : public DPF {
         return expansion[index];
     }
 
+    // The depth
+    inline nbits_t depth() const { return cw.size(); }
+
     // Get the leaf node for the given input
     //
     // Cost: depth AES operations