projects
/
platform
/
upstream
/
libphonenumber.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0c2637c
)
CPP: Fix build issue
author
Cecilia Roes
<roes@google.com>
Fri, 14 Nov 2014 11:54:11 +0000
(11:54 +0000)
committer
Youngjae Shin
<yj99.shin@samsung.com>
Tue, 9 Jun 2015 11:43:22 +0000
(20:43 +0900)
cpp/src/phonenumbers/base/basictypes.h
patch
|
blob
|
history
diff --git
a/cpp/src/phonenumbers/base/basictypes.h
b/cpp/src/phonenumbers/base/basictypes.h
index
ac63259
..
b54abb7
100644
(file)
--- a/
cpp/src/phonenumbers/base/basictypes.h
+++ b/
cpp/src/phonenumbers/base/basictypes.h
@@
-194,9
+194,13
@@
struct CompileAssert {
};
#if !defined(COMPILE_ASSERT)
+#if __cplusplus >= 201103L
+#define COMPILE_ASSERT(expr, msg) static_assert(expr, #msg)
+#else
#define COMPILE_ASSERT(expr, msg) \
typedef CompileAssert<(bool(expr))> msg[bool(expr) ? 1 : -1]
#endif
+#endif
} // namespace phonenumbers
} // namespace i18n