From patchwork Sat Jul 18 20:26:23 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ramsay Jones X-Patchwork-Id: 36208 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n6IL9qsX006441 for ; Sat, 18 Jul 2009 21:09:52 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753609AbZGRVJr (ORCPT ); Sat, 18 Jul 2009 17:09:47 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753670AbZGRVJr (ORCPT ); Sat, 18 Jul 2009 17:09:47 -0400 Received: from anchor-post-3.mail.demon.net ([195.173.77.134]:41055 "EHLO anchor-post-3.mail.demon.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753609AbZGRVJq (ORCPT ); Sat, 18 Jul 2009 17:09:46 -0400 Received: from ramsay1.demon.co.uk ([193.237.126.196]) by anchor-post-3.mail.demon.net with esmtp (Exim 4.69) id 1MSHA9-0005Lw-nP; Sat, 18 Jul 2009 21:09:45 +0000 Message-ID: <4A622FEF.2010704@ramsay1.demon.co.uk> Date: Sat, 18 Jul 2009 21:26:23 +0100 From: Ramsay Jones User-Agent: Thunderbird 1.5.0.2 (Windows/20060308) MIME-Version: 1.0 To: Ramsay Jones CC: Christopher Li , Al Viro , Junio C Hamano , Andreas Ericsson , Sparse Mailing-list Subject: Re: Multiple translation unit regression References: <4A5131F4.7070007@ramsay1.demon.co.uk> <70318cbf0907060232j7067f7fcra857b71ebdf62348@mail.gmail.com> <70318cbf0907062327u51a4253fub2c0f1b2f64c1a@mail.gmail.com> <4A54F452.8030601@ramsay1.demon.co.uk> <70318cbf0907081315w1e066a1fiac24b1b58ef146bb@mail.gmail.com> <4A57AA66.4080305@ramsay1.demon.co.uk> <70318cbf0907101627w1b9760a4oc7d13969751e3d00@mail.gmail.com> <4A5B7257.9090409@ramsay1.demon.co.uk> In-Reply-To: <4A5B7257.9090409@ramsay1.demon.co.uk> Sender: linux-sparse-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sparse@vger.kernel.org Ramsay Jones wrote: > Christopher Li wrote: >> I attach the patch follows. Can you give it a try? >> > > Yep, this works. > Tested on cygwin and Linux. > > Thanks! > BTW, I forgot to mention that I changed the test file so that it would fail before applying the rest of this patch, and pass afterward. I've attached the new file. The diff is as follows: -->8-- -->8-- HTH. ATB, Ramsay Jones extern __inline__ int f(int); extern __inline__ int f(int x) { return x; } extern int g(int); extern __inline__ int g(int x) { return x; } /* * check-name: extern inline function * check-command: sparse $file $file * check-description: Extern inline function never emits stand alone copy * of the function. It allows multiple such definitions in different file. */ diff --git a/validation/extern-inline.c b/validation/extern-inline.c index 13af438..4f12ac0 100644 --- a/validation/extern-inline.c +++ b/validation/extern-inline.c @@ -17,6 +17,7 @@ g(int x) /* * check-name: extern inline function + * check-command: sparse $file $file * check-description: Extern inline function never emits stand alone copy * of the function. It allows multiple such definitions in different file. */