Julia Lawall <[email protected]> writes:

> On Sat, 17 Feb 2018, Robert Larice wrote:
>
>> Hello,
>>
>>   attached is a small example which seems to
>>     break up a comment line,
>>     thus commenting out following lines.
>>
>>   Please look at the "long reuse" line
>>     which will have an open comment when spatch is run,
>>     thus commenting out the following "struct line *options"
>
> I also see this undesriable behavior.  Thanks for the report.
>
> julia

grepping a bit in the source code I found this:
  cpp_eat_until_nl
perhaps in the vicinity of the issue.

and there is this comment somewhere:

(* cpp recognize C comments, so when #define xx (yy) /* comment \n ... */
 * then he has already erased the /* comment. So:
 * - dont eat the start of the comment otherwise afterwards we are in the middle
 *   of a comment and so will problably get a parse error somewhere.
 * - have to recognize comments in cpp_eat_until_nl.
 *)

_______________________________________________
Cocci mailing list
[email protected]
https://systeme.lip6.fr/mailman/listinfo/cocci

Reply via email to