From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25625 invoked by alias); 29 Apr 2012 12:17:29 -0000 Received: (qmail 25614 invoked by uid 22791); 29 Apr 2012 12:17:27 -0000 X-SWARE-Spam-Status: No, hits=-4.3 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,KHOP_THREADED X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 29 Apr 2012 12:17:15 +0000 From: "broken.zhou at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/51625] -Wconversion should be on by default, or at least included in -Wall Date: Sun, 29 Apr 2012 12:17:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: broken.zhou at gmail dot com X-Bugzilla-Status: RESOLVED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Changed-Fields: CC Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2012-04/txt/msg02553.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51625 Yichao Zhou changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |broken.zhou at gmail dot | |com --- Comment #4 from Yichao Zhou 2012-04-29 12:16:54 UTC --- I run into this problem today too. Why gcc do not warning by default when we assign a double to a int? This is even not warned by Wall and Wextra. If you google the internet, you will find there are many users asking this question. > This tied with the fact that there is no data-flow in front-ends (see next question) results in hard to avoid warnings for perfectly working and valid code. This is not convincing for me. Since I think you should do these conversion explicitly to tell others you know what you are doing. I hope that there is a day that the developer can change their mind on this question:)