This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/60114] New: Incorrect column number for -pedantic and -Wconversion
- From: "chengniansun at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Sat, 08 Feb 2014 02:08:33 +0000
- Subject: [Bug c/60114] New: Incorrect column number for -pedantic and -Wconversion
- Auto-submitted: auto-generated
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60114
Bug ID: 60114
Summary: Incorrect column number for -pedantic and -Wconversion
Product: gcc
Version: 4.9.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: chengniansun at gmail dot com
The column number in the warnings by -pedantic and -Wconversion is not precise.
$: cat short.c
int l[9] = {0xD051BC10L,0x976F2A4DL,0x976F2A4DL};
$: gcc-trunk -c -pedantic short.c
short.c:1:1: warning: overflow in implicit constant conversion [-Woverflow]
int l[9] = {0xD051BC10L,0x976F2A4DL,0x976F2A4DL};
^
short.c:1:1: warning: overflow in implicit constant conversion [-Woverflow]
short.c:1:1: warning: overflow in implicit constant conversion [-Woverflow]
$: gcc-trunk -c -Wconversion short.c
short.c:1:1: warning: conversion to âintâ alters âlong intâ constant value
[-Wconversion]
int l[9] = {0xD051BC10L,0x976F2A4DL,0x976F2A4DL};
^
short.c:1:1: warning: conversion to âintâ alters âlong intâ constant value
[-Wconversion]
short.c:1:1: warning: conversion to âintâ alters âlong intâ constant value
[-Wconversion]