[cfe-users] Clang Analyzer: false positive or am I missing something?

2016-06-25 Thread Andrew Fuller via cfe-users
I'm trying to understand an issue reported by Clang's static analysis tool. The code below demonstrates the issue: $ cat problem.c #include int main() { #if VARIANT==1 uint32_t data = 0xdeadbeef; uint8_t* byte = (uint8_t*)&data; uint8_t value = byte[0]; #elif VARIANT==2 uint32_t dat

Re: [cfe-users] Clang Analyzer: false positive or am I missing something?

2016-06-25 Thread Jeffrey Walton via cfe-users
On Sat, Jun 25, 2016 at 2:01 PM, Andrew Fuller via cfe-users wrote: > I'm trying to understand an issue reported by Clang's static analysis tool. > The code below demonstrates the issue: > > $ cat problem.c > #include > > int main() { > #if VARIANT==1 >uint32_t data = 0xdeadbeef; >uint8_t

[cfe-users] Use of undeclared identifier '_tzcnt_u64'

2016-06-25 Thread Jeffrey Walton via cfe-users
Hi Everyone, We got a user report of a compile failure using Apple's Clang. I don't know the exact Apple Clang version at the moment. Its on OS X 10.11, and its probably the one bundled with the latest Xcode. Here's the error report (https://groups.google.com/forum/#!topic/cryptopp-users/BI8yGpr2

Re: [cfe-users] Clang Analyzer: false positive or am I missing something?

2016-06-25 Thread Andrew Fuller via cfe-users
On Sat, Jun 25, 2016 at 6:25 PM, Jeffrey Walton wrote: > On Sat, Jun 25, 2016 at 2:01 PM, Andrew Fuller via cfe-users > wrote: > > I'm trying to understand an issue reported by Clang's static analysis > tool. > > The code below demonstrates the issue: > > > > $ cat problem.c > > #include > > >