dwave-hybrid icon indicating copy to clipboard operation
dwave-hybrid copied to clipboard

Make `Branch` constructor consistent with other composite runnables

Open randomir opened this issue 5 years ago • 0 comments

While other composing runnables take children runnables as positional arguments (children-accepting: Branches, Parallel, Race; child-accepting: Loop, Map, Unwind), Branch takes its children in a single argument, components.

Although there are benefits of this approach (lazy composition/iteration, explicitness), and Branch constructor is rarely used explicitly (usually implicitly with | operator), the inconsistency can be confusing for users (see #207).

randomir avatar Oct 03 '19 13:10 randomir