summaryrefslogtreecommitdiffstats
path: root/Tests/CompileFeatures
diff options
context:
space:
mode:
authorStephen Kelly <steveire@gmail.com>2014-04-06 08:09:37 (GMT)
committerStephen Kelly <steveire@gmail.com>2014-04-08 09:05:57 (GMT)
commit1889045ca672e295c18203401c27a9e62ff45424 (patch)
tree80cbacfb0748db4eff985333ac8cca2ac86fefd8 /Tests/CompileFeatures
parentab455ebafd55653f87168d9e6c32cfc15403a973 (diff)
downloadCMake-1889045ca672e295c18203401c27a9e62ff45424.zip
CMake-1889045ca672e295c18203401c27a9e62ff45424.tar.gz
CMake-1889045ca672e295c18203401c27a9e62ff45424.tar.bz2
Features: Add cxx_sizeof_member.
Diffstat (limited to 'Tests/CompileFeatures')
-rw-r--r--Tests/CompileFeatures/cxx_sizeof_member.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/Tests/CompileFeatures/cxx_sizeof_member.cpp b/Tests/CompileFeatures/cxx_sizeof_member.cpp
new file mode 100644
index 0000000..ae143d2
--- /dev/null
+++ b/Tests/CompileFeatures/cxx_sizeof_member.cpp
@@ -0,0 +1,10 @@
+
+struct A
+{
+ int m_i;
+};
+
+int someFunc()
+{
+ return sizeof(A::m_i) > 0 ? 1 : 2;
+}