summaryrefslogtreecommitdiffstats
path: root/libcxx/src/experimental/filesystem
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2018-07-25 21:01:45 +0000
committerEric Fiselier <eric@efcs.ca>2018-07-25 21:01:45 +0000
commitd77f3ef4a4e7de3c2e926ee6faa4c6942fa2c657 (patch)
treeb6f5019feb043a95538b14d1d7db1fccb8f1a4d8 /libcxx/src/experimental/filesystem
parent0887cf9caba73b9800f6d46f51a098793fb00022 (diff)
downloadbcm5719-llvm-d77f3ef4a4e7de3c2e926ee6faa4c6942fa2c657.tar.gz
bcm5719-llvm-d77f3ef4a4e7de3c2e926ee6faa4c6942fa2c657.zip
Make <experimental/filesystem> compile with gcc 4.8.5
Patch by Victor Zverovich. This fixes an error when compiling `<experimental/filesystem>` with gcc 4.8.5: ``` .../libcxx/src/experimental/filesystem/filesystem_common.h:137:34: error: redeclaration ‘T std::experimental::filesystem::v1::detail::{anonymous}::error_value() [with T = bool]’ d iffers in ‘constexpr’ constexpr bool error_value<bool>() { ^ .../libcxx/src/experimental/filesystem/filesystem_common.h:133:3: error: from previous declaration ‘T std::experimental::filesystem::v1::detail::{anonymous}::error_value() [with T = bool]’ T error_value(); ^ ``` Reviewed as https://reviews.llvm.org/D49813 llvm-svn: 337962
Diffstat (limited to 'libcxx/src/experimental/filesystem')
-rw-r--r--libcxx/src/experimental/filesystem/filesystem_common.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/libcxx/src/experimental/filesystem/filesystem_common.h b/libcxx/src/experimental/filesystem/filesystem_common.h
index 7be16746016..43453a0ad0a 100644
--- a/libcxx/src/experimental/filesystem/filesystem_common.h
+++ b/libcxx/src/experimental/filesystem/filesystem_common.h
@@ -118,11 +118,11 @@ T error_value();
template <>
_LIBCPP_CONSTEXPR_AFTER_CXX11 void error_value<void>() {}
template <>
-constexpr bool error_value<bool>() {
+bool error_value<bool>() {
return false;
}
template <>
-constexpr uintmax_t error_value<uintmax_t>() {
+uintmax_t error_value<uintmax_t>() {
return uintmax_t(-1);
}
template <>
OpenPOWER on IntegriCloud