File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change @@ -375,18 +375,19 @@ void string_dependenciest::for_each_successor(
375
375
const nodet &node,
376
376
const std::function<void (const nodet &)> &f) const
377
377
{
378
- if (node.kind == nodet::BUILTIN )
378
+ switch (node.kind )
379
379
{
380
- for_each_dependency (
381
- builtin_function_nodes[node.index ],
382
- [&](const string_nodet &n) { return f (nodet (n)); });
383
- }
384
- else
385
- {
386
- INVARIANT (node.kind == nodet::STRING, " nodes are either BUILTIN or STRING" );
387
- for_each_dependency (
388
- string_nodes[node.index ],
389
- [&](const builtin_function_nodet &n) { return f (nodet (n)); });
380
+ case nodet::BUILTIN:
381
+ for_each_dependency (
382
+ builtin_function_nodes[node.index ],
383
+ [&](const string_nodet &n) { return f (nodet (n)); });
384
+ break ;
385
+
386
+ case nodet::STRING:
387
+ for_each_dependency (
388
+ string_nodes[node.index ],
389
+ [&](const builtin_function_nodet &n) { return f (nodet (n)); });
390
+ break ;
390
391
}
391
392
}
392
393
You can’t perform that action at this time.
0 commit comments