Commit 2027c0b9 authored by Edward Welbourne's avatar Edward Welbourne
Browse files

Duplicate trivial code for clarity on early return.


Having a variable in which to store a function's return in two
branches of a switch in order to return if either was true saved
little relative to just testing the function in each case and
returning in situ, which reads more clearly.

Change-Id: Ibd95a95721eaa6fc4861b10e723038b96caf269a
Reviewed-by: default avatarTimur Pocheptsov <timur.pocheptsov@theqtcompany.com>
parent d0b54ced
Showing with 4 additions and 7 deletions
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment