title: Gremlin traversal referencing previous edges
body: <p>I have a fairly simple graph, with the caveat that all edges are marked with 'to' and 'from' dates stored as timestamps.</p>
  <p>I'm trying to write a traversal that will only follow edges that overlap with the first traversed edge's To and From dates.</p>
  <p>Note that the To-date can be non-existent, indicating that the edge is still active.</p>
  <p>I've tried various things, but the closest I've come so far is:</p>
  <pre><code>g.V('1').outE().as('firstEdge')
  .sideEffect(values('To').store('eTo'))
  .sideEffect(values('From').store('eFrom'))
  .outV()
  .repeat(outE().where(
      lte('firstEdge')).by('From') // The edge has a from-date less than firstEdge's from-date.
      .and(
          or(
              hasNot('To'), // The edge is still active, OR
              has('To', gte('eFrom')) // the edge has a to date after the firstEdge's from-date.
            )
      )
      .and(
          or(
              select('firstEdge').hasNot('To'), // The first edge does not have a to-date, OR
              has('From', lte('eTo')) // The edge has a from date that is less than the first edge's to-date.
          )
      )
      .inV()
  )
  .emit()
  .times(2) // Limit to two edges away.
  .where(hasLabel('Person'))
  </code></pre>
  <p>I'm pretty sure the problem is related to the store commands and subsequent usage, as the following query does not return anything either (It should return any inactive edges created after the first edge).</p>
  <pre><code>g.V('1').outE('is_board')
      .sideEffect(values('From').store('eFrom'))
      .outV()
      .repeat(outE().has('To', gte('eFrom')).inV())
      .emit()
      .times(2)
      .where(hasLabel('Person'))
  </code></pre>