a slightly more concise version
Posted Mar 31, 2010 13:27 UTC (Wed) by
lawall (guest, #56234)
Parent article:
Evolutionary development of a semantic patch using Coccinelle
The following pattern:
(
i2c_set_clientdata(client, data);
|
data = i2c_get_clientdata(client);
|
T data = i2c_get_clientdata(client);
)
could probably be more concise as:
(
i2c_set_clientdata(client, data)
|
data = i2c_get_clientdata(client)
)
Note the lack of semicolons. The pattern data = i2c_get_clientdata(client) will also match the case of a variable declaration.
julia
(
Log in to post comments)