Re: [PATCH] usb: isp1760: compress return logic into one line

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Oliver,

Quoting Oliver Neukum <oneukum@xxxxxxxx>:

Am Sonntag, den 09.07.2017, 21:00 -0500 schrieb  Gustavo A. R. Silva :
Simplify return logic to avoid unnecessary variable assignment.

This issue was detected using Coccinelle and the following
semantic patch:


Hi,

I need to ask: Where is the improvement? The compiler does not bother
and for the human reader you do not do anything obvious and you
decreased grepability.


The declaration of local variable _retval_ was removed also.
So both, variable declaration and assignment removal are the improvements.

Regarding the greability, I think that depends on the context.

Thanks!
--
Gustavo A. R. Silva




--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux