[Cocci] Wrong regex example in manual

Julia Lawall julia.lawall at lip6.fr
Wed Nov 30 07:30:07 CET 2011


Fixed.  Thanks for pointing it out (it was left over from an old version).

julia

On Tue, 29 Nov 2011, Dmitry Osmakov wrote:

> Based on
> http://cocci.ekstranet.diku.dk/wiki/doku.php?id=refine_matching_on_identifiers_with_regexp_on_identifier_name
> and my experiments this patch may be useful.
>
> diff --git a/docs/manual/examples.tex b/docs/manual/examples.tex
> index 22951cc..af60e10 100644
> --- a/docs/manual/examples.tex
> +++ b/docs/manual/examples.tex
> @@ -448,7 +448,7 @@ print "Identifier: %s" % x
>
> @M at contains@
> type t;
> -identifier foo ~= ".*foo";
> +identifier foo =~ ".*foo";
> @@@M
> t foo () {...}
>
> @@ -462,7 +462,7 @@ print "Contains foo: %s" % x
> \begin{lstlisting}[language=Cocci,name=Regexp]
> @M at endsby@
> type t;
> -identifier foo ~= ".*foo$";
> +identifier foo =~ ".*foo$";
> @@@M
>
> t foo () {...}
> @@ -474,7 +474,7 @@ print "Ends by foo: %s" % x
>
> @M at beginsby@
> type t;
> -identifier foo ~= "^foo";
> +identifier foo =~ "^foo";
> @@@M
> t foo () {...}
>
>
> _______________________________________________
> Cocci mailing list
> Cocci at diku.dk
> http://lists.diku.dk/mailman/listinfo/cocci
> (Web access from inside DIKUs LAN only)
>


More information about the Cocci mailing list