From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.93; helo=mga11.intel.com; envelope-from=liming.gao@intel.com; receiver=edk2-devel@lists.01.org Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 0B23021F3B3F8 for ; Sun, 29 Oct 2017 22:14:20 -0700 (PDT) Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 29 Oct 2017 22:18:10 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,318,1505804400"; d="scan'208";a="143730957" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by orsmga004.jf.intel.com with ESMTP; 29 Oct 2017 22:18:09 -0700 Received: from fmsmsx118.amr.corp.intel.com (10.18.116.18) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.319.2; Sun, 29 Oct 2017 22:18:09 -0700 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by fmsmsx118.amr.corp.intel.com (10.18.116.18) with Microsoft SMTP Server (TLS) id 14.3.319.2; Sun, 29 Oct 2017 22:18:08 -0700 Received: from shsmsx104.ccr.corp.intel.com ([169.254.5.152]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.213]) with mapi id 14.03.0319.002; Mon, 30 Oct 2017 13:18:06 +0800 From: "Gao, Liming" To: "Alcantara, Paulo" , "Carsey, Jaben" , "edk2-devel@lists.01.org" CC: "Ni, Ruiyu" Thread-Topic: [PATCH] ShellPkg: Fix type mismatch with GCC Thread-Index: AQHTT1IksQDT8KLr/0GoIV/kP4kX8KL3hDUAgARYbfA= Date: Mon, 30 Oct 2017 05:18:05 +0000 Message-ID: <4A89E2EF3DFEDB4C8BFDE51014F606A14E172312@SHSMSX104.ccr.corp.intel.com> References: , In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH] ShellPkg: Fix type mismatch with GCC X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Oct 2017 05:14:21 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable I suggest to rename it and add its implementation in ShellPkg. We don't exp= ect to use the internal function from another library or driver.=20 Another way is to propose adding StrniCmp() API into BaseLib.=20 Thanks Liming >-----Original Message----- >From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of >Alcantara, Paulo >Sent: Saturday, October 28, 2017 2:51 AM >To: Carsey, Jaben ; edk2-devel@lists.01.org >Cc: Ni, Ruiyu >Subject: Re: [edk2] [PATCH] ShellPkg: Fix type mismatch with GCC > >Hi Jaben, > >No, we can't. InternalCharToUpper() is declared internally in BaseLib and >unexported. > >The comment above the declaration in UefiShellLevel2CommandsLib.c >explains it: > >/** > Be lazy and borrow from baselib. > > @param[in] Char The character to convert to upper case. > > @return Char as an upper case character. >**/ > >Thanks, >Paulo > >________________________________________ >From: Carsey, Jaben >Sent: Friday, October 27, 2017 4:33 PM >To: Alcantara, Paulo; edk2-devel@lists.01.org >Cc: Ni, Ruiyu >Subject: RE: [PATCH] ShellPkg: Fix type mismatch with GCC > >Are we redefining a function from BaseLib? Why not remove the redundant >definition instead of making it match? > >-Jaben > >> -----Original Message----- >> From: Paulo Alcantara [mailto:paulo@hp.com] >> Sent: Friday, October 27, 2017 9:24 AM >> To: edk2-devel@lists.01.org >> Cc: Paulo Alcantara ; Carsey, Jaben >> ; Ni, Ruiyu >> Subject: [PATCH] ShellPkg: Fix type mismatch with GCC >> Importance: High >> >> This patch fixes the following warning reported by GCC 6.3: >> >> >/home/pcacjr/src/edk2.git/ShellPkg/Library/UefiShellLevel2CommandsLib/U >> efiShellLevel2CommandsLib.c:271:1: >> warning: type of 'InternalCharToUpper' does not match original decl >> aration [-Wlto-type-mismatch] >> InternalCharToUpper ( >> ^ >> /home/pcacjr/src/edk2.git/MdePkg/Library/BaseLib/String.c:555:1: note: >> 'InternalCharToUpper' was previously declared here >> InternalCharToUpper ( >> ^ >> >> Cc: Jaben Carsey >> Cc: Ruiyu Ni >> Contributed-under: TianoCore Contribution Agreement 1.1 >> Signed-off-by: Paulo Alcantara >> --- >> >> >ShellPkg/Library/UefiShellLevel2CommandsLib/UefiShellLevel2CommandsLib >> .c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git >> >a/ShellPkg/Library/UefiShellLevel2CommandsLib/UefiShellLevel2Commands >> Lib.c >> >b/ShellPkg/Library/UefiShellLevel2CommandsLib/UefiShellLevel2Commands >> Lib.c >> index 7948e53cfc..bab6631e15 100644 >> --- >> >a/ShellPkg/Library/UefiShellLevel2CommandsLib/UefiShellLevel2Commands >> Lib.c >> +++ >> >b/ShellPkg/Library/UefiShellLevel2CommandsLib/UefiShellLevel2Commands >> Lib.c >> @@ -268,6 +268,7 @@ VerifyIntermediateDirectories ( >> @return Char as an upper case character. >> **/ >> CHAR16 >> +EFIAPI >> InternalCharToUpper ( >> IN CONST CHAR16 Char >> ); >> -- >> 2.11.0 > >_______________________________________________ >edk2-devel mailing list >edk2-devel@lists.01.org >https://lists.01.org/mailman/listinfo/edk2-devel