Author: ericwf Date: Wed Jul 25 14:53:43 2018 New Revision: 337970 URL: http://llvm.org/viewvc/llvm-project?rev=337970&view=rev Log: Fix failing test under C++14
Modified: libcxx/trunk/src/experimental/filesystem/filesystem_common.h Modified: libcxx/trunk/src/experimental/filesystem/filesystem_common.h URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/src/experimental/filesystem/filesystem_common.h?rev=337970&r1=337969&r2=337970&view=diff ============================================================================== --- libcxx/trunk/src/experimental/filesystem/filesystem_common.h (original) +++ libcxx/trunk/src/experimental/filesystem/filesystem_common.h Wed Jul 25 14:53:43 2018 @@ -362,8 +362,8 @@ public: // The tv_nsec and tv_usec fields must not be negative so adjust accordingly if (subsec_dur.count() < 0) { if (sec_dur.count() > min_seconds) { - sec_dur -= fs_seconds(1); - subsec_dur += fs_seconds(1); + sec_dur = sec_dur - fs_seconds(1); + subsec_dur = subsec_dur + fs_seconds(1); } else { subsec_dur = fs_nanoseconds::zero(); } _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits