From: Alessandro Carminati <alessandro.carminati@gmail.com>
To: cocci@inria.fr
Subject: [cocci] Fwd: List global variables.
Date: Mon, 9 May 2022 12:49:14 +0200 [thread overview]
Message-ID: <CAPp5cGS+ANKVuE+QThN=Byqm=BR0FotbCe7aQgjX77Ee65UDuQ@mail.gmail.com> (raw)
In-Reply-To: <CAPp5cGRMAOanfvuhV1LAV9eZka8ZJHRPy6ncMwO=Q+C=GUA2gA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 975 bytes --]
Hello Julia,
The solution you sent indeed does what I expected.
Although I needed a solution for this specific case, and yours fit my needs
perfectly, I'd love it if you wanted to explain it to me.
Would you mind add a short explanation of this statement:
`position p : script:python(i) { p[0].current_element == i};`
I probably have a simplified understanding of what a position is. Maybe it
is worth digging deeper and having a more concrete knowledge. Any read you
want to suggest to me?
Thank you for your time.
Alessandro
Il giorno lun 9 mag 2022 alle ore 12:17 Julia Lawall <julia.lawall@inria.fr>
ha scritto:
>
>
> On Mon, 9 May 2022, Alessandro Carminati wrote:
>
> > Hello,I need to build a tool that just lists the global variables for a
> > given c project.
>
> @r@
> type T;
> identifier i;
> position p : script:python(i) { p[0].current_element == i};
> @@
>
> *T i@p;
>
> The * is just for illustration. You can do whatever you want with i.
>
> julia
>
[-- Attachment #2: Type: text/html, Size: 1667 bytes --]
next prev parent reply other threads:[~2022-05-09 10:49 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-09 10:05 [cocci] List global variables Alessandro Carminati
2022-05-09 10:11 ` Julia Lawall
2022-05-09 10:17 ` Julia Lawall
[not found] ` <CAPp5cGRMAOanfvuhV1LAV9eZka8ZJHRPy6ncMwO=Q+C=GUA2gA@mail.gmail.com>
2022-05-09 10:49 ` Alessandro Carminati [this message]
2022-05-09 11:49 ` [cocci] Fwd: " Julia Lawall
2022-05-09 19:23 ` [cocci] List global variables with SmPL Markus Elfring
2022-05-10 7:52 ` Alessandro Carminati
2022-05-10 8:06 ` Julia Lawall
2022-05-10 9:18 ` Alessandro Carminati
2022-05-10 9:24 ` Julia Lawall
2022-05-10 9:53 ` Alessandro Carminati
2022-05-10 10:39 ` Julia Lawall
2022-05-10 17:00 ` Markus Elfring
2022-05-21 14:05 ` Markus Elfring
2022-05-11 7:38 ` Alessandro Carminati
2022-05-11 7:44 ` Julia Lawall
2022-05-11 7:57 ` Alessandro Carminati
2022-05-11 8:14 ` Julia Lawall
2022-05-11 8:36 ` Alessandro Carminati
2022-05-11 8:46 ` Julia Lawall
2022-05-11 19:54 ` Markus Elfring
2022-05-11 18:11 ` Markus Elfring
2022-05-12 6:42 ` Alessandro Carminati
2022-05-12 16:48 ` Markus Elfring
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='CAPp5cGS+ANKVuE+QThN=Byqm=BR0FotbCe7aQgjX77Ee65UDuQ@mail.gmail.com' \
--to=alessandro.carminati@gmail.com \
--cc=cocci@inria.fr \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.