I have a semantic patch that renames parameters and local variables
called `index` to `idx`. It renames most occurrences, however,
it does not know how to handle a macro that expands to a block:
#define HGOTO_ERROR(maj, min, ret_val, ...) { \
do_something(maj, min, __VA_ARGS__); \
ret_value = ret_val; \
goto done; \
}
I'd like for every occurrence of `index` in the HGOTO_ERROR() arguments
to change to `idx`, HGOTO_ERROR(..., index, ...) -> HGOTO_ERROR(..., idx, ...),
but spatch leaves those occurrences alone.
Can I write an isomorphism or something to force spatch to process each
occurrence of HGOTO_ERROR(...) as if it was either the function call
`hgoto_error(...);` or the block `{ (void)(...); goto done; }` ?
Dave
--
David Young
[email protected] Urbana, IL (217) 721-9981
_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci