Linux Kernel Mentees Archive on lore.kernel.org
 help / color / Atom feed
* Re: [Linux-kernel-mentees] [Cocci] [PATCH 1/2] parsing_c: Align C AST and Cocci AST for const pointer variants
@ 2020-02-08  8:30 Markus Elfring
  2020-02-08 12:41 ` Jaskaran Singh
  0 siblings, 1 reply; 4+ messages in thread
From: Markus Elfring @ 2020-02-08  8:30 UTC (permalink / raw)
  To: Jaskaran Singh, cocci; +Cc: linux-kernel-mentees

> For a pointer, the C parser constructed an AST dissimilar from that
> of the Cocci AST. This caused failures in matching with certain
> pointer types. For example, for the following case:
>
> char *1 const *2 id;
>
> The C AST constructed would be:
> const Pointer1 -> Pointer2 -> char
>
> The Cocci AST constructed would be:
> Pointer2 -> const Pointer1 -> char

Which software development tools support to check such information?

Regards,
Markus
_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Linux-kernel-mentees] [Cocci] [PATCH 1/2] parsing_c: Align C AST and Cocci AST for const pointer variants
  2020-02-08  8:30 [Linux-kernel-mentees] [Cocci] [PATCH 1/2] parsing_c: Align C AST and Cocci AST for const pointer variants Markus Elfring
@ 2020-02-08 12:41 ` Jaskaran Singh
  2020-02-08 12:56   ` [Linux-kernel-mentees] Linux dev-tools: Handling complex types and attributes in Coccinelle Markus Elfring
  2020-02-08 12:56   ` Markus Elfring
  0 siblings, 2 replies; 4+ messages in thread
From: Jaskaran Singh @ 2020-02-08 12:41 UTC (permalink / raw)
  To: Markus Elfring; +Cc: Julia Lawall, linux-kernel-mentees, cocci

On Sat, 2020-02-08 at 09:30 +0100, Markus Elfring wrote:
> > For a pointer, the C parser constructed an AST dissimilar from that
> > of the Cocci AST. This caused failures in matching with certain
> > pointer types. For example, for the following case:
> > 
> > char *1 const *2 id;
> > 
> > The C AST constructed would be:
> > const Pointer1 -> Pointer2 -> char
> > 
> > The Cocci AST constructed would be:
> > Pointer2 -> const Pointer1 -> char
> 
> Which software development tools support to check such information?
> 

A little collection of scripts/tools I've written[1], and the
invaluable OCaml debugger :)

Cheers,
Jaskaran.

[1]http://github.com/jajajasalu2/cocci-type-test-suite

> Regards,
> Markus

_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Linux-kernel-mentees] Linux dev-tools: Handling complex types and attributes in Coccinelle
  2020-02-08 12:41 ` Jaskaran Singh
@ 2020-02-08 12:56   ` Markus Elfring
  2020-02-08 12:56   ` Markus Elfring
  1 sibling, 0 replies; 4+ messages in thread
From: Markus Elfring @ 2020-02-08 12:56 UTC (permalink / raw)
  To: Jaskaran Singh, cocci; +Cc: Julia Lawall, linux-kernel-mentees

> A little collection of scripts/tools I've written[1],

Thanks for your link on another bit of background information.
https://github.com/jajajasalu2/cocci-type-test-suite

Would you like to point any related information sources out?


> and the invaluable OCaml debugger :)

This development tool can help occasionally.


I am curious if your contributions will influence also other known open issues
for this software in positive ways.

Regards,
Markus
_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [Linux-kernel-mentees] Linux dev-tools: Handling complex types and attributes in Coccinelle
  2020-02-08 12:41 ` Jaskaran Singh
  2020-02-08 12:56   ` [Linux-kernel-mentees] Linux dev-tools: Handling complex types and attributes in Coccinelle Markus Elfring
@ 2020-02-08 12:56   ` Markus Elfring
  1 sibling, 0 replies; 4+ messages in thread
From: Markus Elfring @ 2020-02-08 12:56 UTC (permalink / raw)
  To: Jaskaran Singh, cocci; +Cc: Julia Lawall, linux-kernel-mentees

> A little collection of scripts/tools I've written[1],

Thanks for your link on another bit of background information.
https://github.com/jajajasalu2/cocci-type-test-suite

Would you like to point any related information sources out?


> and the invaluable OCaml debugger :)

This development tool can help occasionally.


I am curious if your contributions will influence also other known open issues
for this software in positive ways.

Regards,
Markus
_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, back to index

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-08  8:30 [Linux-kernel-mentees] [Cocci] [PATCH 1/2] parsing_c: Align C AST and Cocci AST for const pointer variants Markus Elfring
2020-02-08 12:41 ` Jaskaran Singh
2020-02-08 12:56   ` [Linux-kernel-mentees] Linux dev-tools: Handling complex types and attributes in Coccinelle Markus Elfring
2020-02-08 12:56   ` Markus Elfring

Linux Kernel Mentees Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-kernel-mentees/0 linux-kernel-mentees/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-kernel-mentees linux-kernel-mentees/ https://lore.kernel.org/linux-kernel-mentees \
		linux-kernel-mentees@lists.linuxfoundation.org
	public-inbox-index linux-kernel-mentees

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.linuxfoundation.lists.linux-kernel-mentees


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git