Skip to content

Commit

Permalink
Move workaround to header
Browse files Browse the repository at this point in the history
  • Loading branch information
kraxarn committed Jan 26, 2025
1 parent 4f32b0b commit da6990f
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 5 deletions.
3 changes: 1 addition & 2 deletions lib/include/lib/cache/jsoncache.hpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
#pragma once

#include "lib/cache.hpp"
#include "lib/filesystem.hpp"
#include "lib/paths/paths.hpp"

#include <filesystem>

namespace lib
{
/**
Expand Down
10 changes: 10 additions & 0 deletions lib/include/lib/filesystem.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#pragma once

// Workaround for
// https://bugreports.qt.io/browse/QTBUG-73263

#ifdef QT_CORE_LIB
#include <QCoreApplication>
#endif

#include <filesystem> // NOLINT(*-include-cleaner)
2 changes: 1 addition & 1 deletion lib/include/lib/json.hpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#pragma once

#include "lib/filesystem.hpp"
#include "thirdparty/json.hpp"

#include <filesystem>
#include <optional>

namespace lib
Expand Down
2 changes: 1 addition & 1 deletion lib/include/lib/paths/paths.hpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#pragma once

#include <filesystem>
#include "lib/filesystem.hpp"

namespace lib
{
Expand Down
2 changes: 1 addition & 1 deletion lib/test/src/settingstests.cpp
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
#include "lib/filesystem.hpp"
#include "lib/log.hpp"
#include "lib/settings.hpp"
#include "lib/paths/paths.hpp"
#include "thirdparty/doctest.h"

#include <filesystem>
#include <fstream>

class test_paths: public lib::paths
Expand Down

0 comments on commit da6990f

Please sign in to comment.