Skip to content

search: simplify query generator control flow

Administrator requested to merge rvt/lucky-query-gen into main

Created by: rvantonder

Simplifies the base case value for the query generator, so the surrounding control flow simplifies to

g := NewGenerator(...)
for g != nil {
  autoQ, g = g()
  // stuff
}

(Rework of https://github.com/sourcegraph/sourcegraph/pull/38698)

Test plan

Semantics-preserving, covered by tests.

Merge request reports

Loading