From: Julia Lawall <julia.lawall@lip6.fr>
To: Timur Tabi <timur@kernel.org>
Cc: cocci <cocci@systeme.lip6.fr>
Subject: Re: [Cocci] Can coccinelle differentiate between a string literal and a string variable?
Date: Tue, 16 Apr 2019 23:48:13 +0200 (CEST) [thread overview]
Message-ID: <alpine.DEB.2.21.1904162347540.2719@hadrien> (raw)
In-Reply-To: <CAOZdJXUtiVjHf2zPZFkhP9j4xcZHAwnyQiZ5Q9d4Jg3Cb6jQ=Q@mail.gmail.com>
On Tue, 16 Apr 2019, Timur Tabi wrote:
> I have a macro that requires one of the parameters to be a string
> literal, rather than a variable (e.g. char x[] or char *x).
>
> Can a coccinelle rule differentiate between the two?
constant char [] c;
julia
> _______________________________________________
> Cocci mailing list
> Cocci@systeme.lip6.fr
> https://systeme.lip6.fr/mailman/listinfo/cocci
>
_______________________________________________
Cocci mailing list
Cocci@systeme.lip6.fr
https://systeme.lip6.fr/mailman/listinfo/cocci
prev parent reply other threads:[~2019-04-16 21:48 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-04-16 21:37 [Cocci] Can coccinelle differentiate between a string literal and a string variable? Timur Tabi
2019-04-16 21:48 ` Julia Lawall [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=alpine.DEB.2.21.1904162347540.2719@hadrien \
--to=julia.lawall@lip6.fr \
--cc=cocci@systeme.lip6.fr \
--cc=timur@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).