[LLVMbugs] [Bug 13541] New: clang print wrong diagnostics for -Wstring-plus-int in some cases
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Mon Aug 6 21:47:53 PDT 2012
http://llvm.org/bugs/show_bug.cgi?id=13541
Bug #: 13541
Summary: clang print wrong diagnostics for -Wstring-plus-int in
some cases
Product: clang
Version: 3.1
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P
Component: Driver
AssignedTo: unassignedclangbugs at nondot.org
ReportedBy: dlmeetei at gmail.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
Here the developer thought the _pift is string and trying to catenate. but
clang
suggests to use indexing which is not correct way.
RUEpProvider.cpp:600:46: warning: adding 'Uint16' (aka 'unsigned short') to a
string does not append to the string [-Wstring-plus-int]
"ProtocolIFType == " + _pift );
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~
RUEpProvider.cpp:600:46: note: use array indexing to silence this warning
"ProtocolIFType == " + _pift );
^
& [ ]
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list