Skip to content
Snippets Groups Projects
Commit a2b29b41 authored by Sam Yates's avatar Sam Yates
Browse files

Address compliance issues with coding guidelines.

parent 7491c8ae
No related branches found
No related tags found
No related merge requests found
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
#include <cstring> #include <cstring>
#include <iomanip> #include <iomanip>
#include <iostream> #include <iostream>
#include <thread> #include <mutex>
#include "util/debug.hpp" #include "util/debug.hpp"
#include "util/ioutil.hpp" #include "util/ioutil.hpp"
...@@ -16,8 +16,8 @@ namespace util { ...@@ -16,8 +16,8 @@ namespace util {
std::mutex global_debug_cerr_mutex; std::mutex global_debug_cerr_mutex;
#endif #endif
bool failed_assertion(const char *assertion, const char *file, bool failed_assertion(const char* assertion, const char* file,
int line, const char *func) int line, const char* func)
{ {
// Explicit flush, as we can't assume default buffering semantics on stderr/cerr, // Explicit flush, as we can't assume default buffering semantics on stderr/cerr,
// and abort() might not flush streams. // and abort() might not flush streams.
...@@ -28,7 +28,9 @@ bool failed_assertion(const char *assertion, const char *file, ...@@ -28,7 +28,9 @@ bool failed_assertion(const char *assertion, const char *file,
return false; return false;
} }
std::ostream& debug_emit_trace_leader(std::ostream &out, const char* file, int line, const char* varlist) { std::ostream& debug_emit_trace_leader(std::ostream& out, const char* file,
int line, const char* varlist)
{
iosfmt_guard _(out); iosfmt_guard _(out);
const char* leaf = std::strrchr(file, '/'); const char* leaf = std::strrchr(file, '/');
......
...@@ -29,7 +29,7 @@ extern std::mutex global_debug_cerr_mutex; ...@@ -29,7 +29,7 @@ extern std::mutex global_debug_cerr_mutex;
#endif #endif
template <typename... Args> template <typename... Args>
void debug_emit_trace(const char *file, int line, const char *varlist, const Args&... args) { void debug_emit_trace(const char* file, int line, const char* varlist, const Args&... args) {
#ifdef WITH_TBB #ifdef WITH_TBB
std::stringstream out; std::stringstream out;
#else #else
......
...@@ -8,7 +8,7 @@ namespace util { ...@@ -8,7 +8,7 @@ namespace util {
class iosfmt_guard { class iosfmt_guard {
public: public:
explicit iosfmt_guard(std::ios &stream): save_(nullptr), stream_(stream) { explicit iosfmt_guard(std::ios& stream) : save_(nullptr), stream_(stream) {
save_.copyfmt(stream_); save_.copyfmt(stream_);
} }
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment