From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.org/gmane.linux.lib.musl.general/10232 Path: news.gmane.org!not-for-mail From: "Zhao, Weiming" Newsgroups: gmane.linux.lib.musl.general Subject: Re: Fix warnings when build with clang Date: Mon, 27 Jun 2016 10:30:51 -0700 Message-ID: References: <20160625093707.GA19691@port70.net> <36ad2a0f7443ff7e95b7e927b49a2a87@codeaurora.org> <20160627172159.GH10893@brightrain.aerifal.cx> Reply-To: musl@lists.openwall.com NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1467048671 24955 80.91.229.3 (27 Jun 2016 17:31:11 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 27 Jun 2016 17:31:11 +0000 (UTC) To: musl@lists.openwall.com Original-X-From: musl-return-10245-gllmg-musl=m.gmane.org@lists.openwall.com Mon Jun 27 19:31:11 2016 Return-path: Envelope-to: gllmg-musl@m.gmane.org Original-Received: from mother.openwall.net ([195.42.179.200]) by plane.gmane.org with smtp (Exim 4.69) (envelope-from ) id 1bHaNJ-0003Hz-RP for gllmg-musl@m.gmane.org; Mon, 27 Jun 2016 19:31:09 +0200 Original-Received: (qmail 23612 invoked by uid 550); 27 Jun 2016 17:31:05 -0000 Mailing-List: contact musl-help@lists.openwall.com; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-ID: Original-Received: (qmail 22493 invoked from network); 27 Jun 2016 17:31:03 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham autolearn_force=no version=3.4.0 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 In-Reply-To: <20160627172159.GH10893@brightrain.aerifal.cx> Xref: news.gmane.org gmane.linux.lib.musl.general:10232 Archived-At: I don't think it's a compiler bug. Neither a functionality issue in MUSL. Its a warning about code readability / sanity and we can fix it in 2 seconds, which can make build process looks more clean. Weiming On 6/27/2016 10:21 AM, Rich Felker wrote: > On Mon, Jun 27, 2016 at 10:01:52AM -0700, weimingz@codeaurora.org wrote: >> On 2016-06-25 02:37, Szabolcs Nagy wrote: >>> * Zhao, Weiming [2016-06-24 17:18:23 -0700]: >>>> Clang gives warnings about the missing parentheses for bitwise ops. >>>> >>>> It's not functional but just code readability. >>>> >>>> musl-m3/include/endian.h:32:25: warning: '&' within '|' >>>> [-Wbitwise-op-parentheses] >>>> return __x>>24 | __x>>8&0xff00 | __x<<8&0xff0000 | __x<<24; >>>> ~ ~~~~~~^~~~~~~ >>> if clang warns about system headers that's a clang bug. >> The endian.h is a musl file. > Right, which is why it's a system header. > > Rich -- Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, hosted by The Linux Foundation