libcruft-util/cruft/util/time_win32.cpp

21 lines
511 B
C++
Raw Permalink Normal View History

2015-07-23 14:13:09 +10:00
/*
2018-08-04 15:14:06 +10:00
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
2015-07-23 14:13:09 +10:00
*
* Copyright 2010-2016 Danny Robson <danny@nerdcruft.net>
2015-07-23 14:13:09 +10:00
*/
#include "time.hpp"
2019-05-05 09:29:35 +10:00
#include <chrono>
#include <thread>
2015-07-23 14:13:09 +10:00
///////////////////////////////////////////////////////////////////////////////
void
cruft::sleep (uint64_t ns)
2015-07-23 14:13:09 +10:00
{
std::this_thread::sleep_for (std::chrono::nanoseconds (ns));
2015-07-23 14:13:09 +10:00
}