summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms/Utils/BuildLibCalls.cpp
diff options
context:
space:
mode:
authorAaron Ballman <aaron@aaronballman.com>2016-09-15 18:07:51 +0000
committerAaron Ballman <aaron@aaronballman.com>2016-09-15 18:07:51 +0000
commita4f597f002e875782cfa1704a81051ba67c9adfd (patch)
treecffb31e0a516a1cc89365b4ad1bc20f898cbe634 /llvm/lib/Transforms/Utils/BuildLibCalls.cpp
parent886a542e2382bbc7dbc027740d50c307fce7e105 (diff)
downloadbcm5719-llvm-a4f597f002e875782cfa1704a81051ba67c9adfd.tar.gz
bcm5719-llvm-a4f597f002e875782cfa1704a81051ba67c9adfd.zip
Reapply: Silence false positive diagnostics regarding passing an object of enumeration type to va_start().
The underlying type for an enumeration in C is either char, signed int, or unsigned int. In the case the underlying type is chosen to be char (such as when passing -fshort-enums or using __attribute__((packed)) on the enum declaration), the enumeration can result in undefined behavior. However, when the underlying type is signed int or unsigned int (or long long as an extension), there is no undefined behavior because the types are compatible. This patch silences diagnostics for the latter while retaining the diagnostics for the former. This patch addresses PR29140. llvm-svn: 281632
Diffstat (limited to 'llvm/lib/Transforms/Utils/BuildLibCalls.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud