From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.1 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS, USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 56830C33CB1 for ; Wed, 15 Jan 2020 15:31:23 +0000 (UTC) Received: from isis.lip6.fr (isis.lip6.fr [132.227.60.2]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E6D242053B for ; Wed, 15 Jan 2020 15:31:22 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="YG+TXbVm" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E6D242053B Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=cocci-bounces@systeme.lip6.fr Received: from systeme.lip6.fr (systeme.lip6.fr [132.227.104.7]) by isis.lip6.fr (8.15.2/8.15.2) with ESMTP id 00FFUplk012481; Wed, 15 Jan 2020 16:30:51 +0100 (CET) Received: from systeme.lip6.fr (systeme.lip6.fr [127.0.0.1]) by systeme.lip6.fr (Postfix) with ESMTP id B974377F5; Wed, 15 Jan 2020 16:30:51 +0100 (CET) Received: from isis.lip6.fr (isis.lip6.fr [132.227.60.2]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by systeme.lip6.fr (Postfix) with ESMTPS id 35B4677E3 for ; Wed, 15 Jan 2020 16:30:50 +0100 (CET) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by isis.lip6.fr (8.15.2/8.15.2) with ESMTP id 00FFUiRU016162 for ; Wed, 15 Jan 2020 16:30:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1579102243; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=HAX1rXQUwtb8vji9FVRFN03Wm3rPqcxy0T3H2JRbiYg=; b=YG+TXbVmTaQeSNpADYSrB37L4yM5I+fd15IGwcxZ+9WfFIDQZvoPBE44z4xp5w+DqWAH2l vurNwKXECOIKB5yI77N+aciOD0dAu0SaioTz3Kf1eLLXjf2zUPe96X1JjzMOAzQwV2Edpg eSpskVXlUyf0/RWiL3Od0fnpaPeknvo= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-99-HU0oTAZtOYKRPzFu-wogEA-1; Wed, 15 Jan 2020 10:30:39 -0500 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 9B3C68EEE6F; Wed, 15 Jan 2020 15:30:37 +0000 (UTC) Received: from dhcp-27-174.brq.redhat.com (unknown [10.43.17.70]) by smtp.corp.redhat.com (Postfix) with SMTP id 6BADF5C219; Wed, 15 Jan 2020 15:30:36 +0000 (UTC) Received: by dhcp-27-174.brq.redhat.com (nbSMTP-1.00) for uid 1000 oleg@redhat.com; Wed, 15 Jan 2020 16:30:37 +0100 (CET) Date: Wed, 15 Jan 2020 16:30:35 +0100 From: Oleg Nesterov To: Julia Lawall Message-ID: <20200115153035.GA9172@redhat.com> References: <20200115112540.GA18161@redhat.com> MIME-Version: 1.0 In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-Scanned-By: MIMEDefang 2.78 on 132.227.60.2 X-Scanned-By: MIMEDefang 2.78 on 132.227.60.2 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-MC-Unique: HU0oTAZtOYKRPzFu-wogEA-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Disposition: inline X-Greylist: Sender IP whitelisted, Sender e-mail whitelisted, not delayed by milter-greylist-4.4.3 (isis.lip6.fr [132.227.60.2]); Wed, 15 Jan 2020 16:30:52 +0100 (CET) X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.4.3 (isis.lip6.fr [132.227.60.2]); Wed, 15 Jan 2020 16:30:44 +0100 (CET) Cc: Julia Lawall , cocci@systeme.lip6.fr Subject: Re: [Cocci] Q: does spatch understand typeof? X-BeenThere: cocci@systeme.lip6.fr X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: cocci-bounces@systeme.lip6.fr Errors-To: cocci-bounces@systeme.lip6.fr On 01/15, Julia Lawall wrote: > > Yes, it doesn't currently understand typeof. If it's a big problem, it > should be easy to fix. OK, thanks Julia. Another question... inc.h: struct TTT { int mem; } *ptr; test.c: #include "inc.h" void func(void) { ptr->mem = 0; } test.cocci: @r@ struct TTT *p; @@ * p->mem $ spatch --sp-file test.cocci test.c (ONCE) Expected tokens mem TTT Skipping: test.c I tried to play with various --.*include.* options, but nothing seems to work unless I add "inc.h" to the command line explicitly. Oleg. _______________________________________________ Cocci mailing list Cocci@systeme.lip6.fr https://systeme.lip6.fr/mailman/listinfo/cocci