linux-kernel-mentees.lists.linuxfoundation.org archive mirror
 help / color / mirror / Atom feed
From: Jaskaran Singh <jaskaransingh7654321@gmail.com>
To: cocci@systeme.lip6.fr
Cc: julia.lawall@inria.fr, jaskaransingh7654321@gmail.com,
	linux-kernel-mentees@lists.linuxfoundation.org
Subject: [Linux-kernel-mentees] [PATCH 12/27] parsing_cocci: single_statement: Reflect struct end attributes
Date: Sun, 31 May 2020 20:56:06 +0530	[thread overview]
Message-ID: <20200531152621.2886-13-jaskaransingh7654321@gmail.com> (raw)
In-Reply-To: <20200531152621.2886-1-jaskaransingh7654321@gmail.com>

Struct end attributes are added to the SmPL AST. Reflect these changes
in single_statement.ml.

Signed-off-by: Jaskaran Singh <jaskaransingh7654321@gmail.com>
---
 parsing_cocci/single_statement.ml | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/parsing_cocci/single_statement.ml b/parsing_cocci/single_statement.ml
index cd1b2c05..df50df6a 100644
--- a/parsing_cocci/single_statement.ml
+++ b/parsing_cocci/single_statement.ml
@@ -205,7 +205,7 @@ and left_declaration d =
   | Ast0.MacroDeclInit(Some stg,name,lp,args,rp,eq,ini,sem) ->
       modif_before_mcode stg
   | Ast0.MacroDeclInit(None,name,lp,args,rp,eq,ini,sem) -> left_ident name
-  | Ast0.TyDecl(ty,sem) -> left_typeC ty
+  | Ast0.TyDecl(ty,attr,sem) -> left_typeC ty
   | Ast0.Typedef(stg,ty,id,sem) -> modif_before_mcode stg
   | Ast0.DisjDecl(_,decls,_,_) -> List.exists left_declaration decls
   | Ast0.ConjDecl(_,decls,_,_) -> List.exists left_declaration decls
@@ -221,7 +221,7 @@ and right_declaration d =
   | Ast0.FunProto(fninfo,name,lp1,params,va,rp1,sem) -> modif_after_mcode sem
   | Ast0.MacroDecl(_,name,lp,args,rp,attr,sem) -> modif_after_mcode sem
   | Ast0.MacroDeclInit(_,name,lp,args,rp,eq,ini,sem) -> modif_after_mcode sem
-  | Ast0.TyDecl(ty,sem) -> modif_after_mcode sem
+  | Ast0.TyDecl(ty,attr,sem) -> modif_after_mcode sem
   | Ast0.Typedef(stg,ty,id,sem) -> modif_after_mcode sem
   | Ast0.DisjDecl(_,decls,_,_) -> List.exists right_declaration decls
   | Ast0.ConjDecl(_,decls,_,_) -> List.exists right_declaration decls
-- 
2.21.1

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

  parent reply	other threads:[~2020-05-31 15:27 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-31 15:25 [Linux-kernel-mentees] [PATCH 00/27] cocci: Add struct end attributes to SmPL Jaskaran Singh
2020-05-31 15:25 ` [Linux-kernel-mentees] [PATCH 01/27] parsing_cocci: ast0_cocci: Add struct end attributes Jaskaran Singh
2020-05-31 15:25 ` [Linux-kernel-mentees] [PATCH 02/27] parsing_cocci: parser: Reflect " Jaskaran Singh
2020-05-31 15:25 ` [Linux-kernel-mentees] [PATCH 03/27] parsing_cocci: visitor_ast0: Visit " Jaskaran Singh
2020-05-31 15:25 ` [Linux-kernel-mentees] [PATCH 04/27] parsing_cocci: unparse_ast0: Reflect " Jaskaran Singh
2020-05-31 15:25 ` [Linux-kernel-mentees] [PATCH 05/27] parsing_cocci: index: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 06/27] parsing_cocci: iso_pattern: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 07/27] parsing_cocci: type_infer: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 08/27] parsing_cocci: arity: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 09/27] parsing_cocci: check_meta: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 10/27] parsing_cocci: compute_lines: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 11/27] parsing_cocci: context_neg: " Jaskaran Singh
2020-05-31 15:26 ` Jaskaran Singh [this message]
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 13/27] parsing_cocci: ast_cocci: Add " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 14/27] parsing_cocci: visitor_ast: Visit " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 15/27] parsing_cocci: pretty_print_cocci: Reflect " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 16/27] parsing_cocci: disjdistr: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 17/27] parsing_cocci: adjust_pragmas: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 18/27] parsing_cocci: unify_ast: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 19/27] parsing_cocci: ast0toast: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 20/27] parsing_c: unparse_cocci: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 21/27] engine: check_exhaustive_pattern: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 22/27] engine: cocci_vs_c: Match " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 23/27] ocaml: coccilib: Reflect " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 24/27] tools: spgen: " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 25/27] tests: Add test case to remove a struct end attribute Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 26/27] tests: Add test case to detect " Jaskaran Singh
2020-05-31 15:26 ` [Linux-kernel-mentees] [PATCH 27/27] tests: Add test case to check struct endattr allminus Jaskaran Singh

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=20200531152621.2886-13-jaskaransingh7654321@gmail.com \
    --to=jaskaransingh7654321@gmail.com \
    --cc=cocci@systeme.lip6.fr \
    --cc=julia.lawall@inria.fr \
    --cc=linux-kernel-mentees@lists.linuxfoundation.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).