blob: 92db763a29f7e4e88790be08a4ae40687a849765 [file] [log] [blame] [raw]
/* Statement isomorphisms - replace explicit checks against NULL with a
* shorter variant, which relies on C's downgrade-to-bool feature.
* The expression metavariables should be declared as pointers, however,
* that doesn't work well with complex expressions like:
* if (UNIT(p)->default_dependencies != NULL)
*/
Statement
@@
expression X;
statement S;
@@
if (X == NULL) S => if (!X) S
Statement
@@
expression X;
statement S;
@@
if (X != NULL) S => if (X) S