| 252 | } |
| 253 | |
| 254 | Status CaseBuilder::BuildLoweredCaseOutput() { |
| 255 | // If outputs are empty, it means that we might have only output control |
| 256 | // edges (already connected to the `branch_executed_node`). Furthermore it's |
| 257 | // illegal to have an IdentityN with empty inputs. |
| 258 | // |
| 259 | // We still must keep lowered Case node as a valid source of control edges, |
| 260 | // because it might be a part of function control output set. |
| 261 | NodeBuilder builder = keep_node_fetchable_ && !outputs_.empty() |
| 262 | ? NodeBuilder(name_, "IdentityN").Input(outputs_) |
| 263 | : NodeBuilder(name_, "NoOp"); |
| 264 | return builder.Device(case_op_->requested_device()) |
| 265 | .ControlInput(branch_executed_node_) |
| 266 | .Finalize(graph_, &lowered_case_output_); |
| 267 | } |
| 268 | |
| 269 | } // namespace |
| 270 |
nothing calls this directly
no test coverage detected