[Bug c++/52654] New: [C++11] Warn on overflow in user-defined literals

marc.glisse at normalesup dot org gcc-bugzilla@gcc.gnu.org
Wed Mar 21 10:48:00 GMT 2012


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52654

             Bug #: 52654
           Summary: [C++11] Warn on overflow in user-defined literals
    Classification: Unclassified
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: marc.glisse@normalesup.org


Hello,

should there be a warning for this kind of overflow? (-Wall -Wextra is
currently silent)

int operator"" _w(unsigned long long){return 0;}
int main(){
  return 12345678901234567890123456789012345678901234567890_w;
}



More information about the Gcc-bugs mailing list