efriedma added inline comments.

================
Comment at: test/CodeGen/builtins.cpp:5
+// RUN: %clang_cc1 -std=c++11 -triple powerpc-pc-linux -verify %s
+// RUN: %clang_cc1 -std=c++11 -triple arm-linux-gnueabi -verify %s
+
----------------
You don't need quite so many targets on this list.  There are essentially three 
interesting kinds of targets: targets where int is 16 bits (like avr), targets 
where int is 32 bits and long is 64 bits (like x86_64 Linux), and targets where 
int and long are both 32 bits (like i686 Linux).

You might need to pass -ffreestanding to avoid including /usr/include/stdint.h 
on non-Linux systems.


================
Comment at: test/CodeGen/builtins.cpp:21
+
+uint16_t bswap16; // expected-note{{previous definition is here}}
+decltype(__builtin_bswap16(0)) bswap16 = 42; // 
expected-error-re{{redefinition of 'bswap16'{{$}}}}
----------------
If you write "extern uint16_t bswap16;", there won't be any error message when 
the types match.


Repository:
  rC Clang

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D61845/new/

https://reviews.llvm.org/D61845



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to