refresh struct

This commit is contained in:
chatlanin 2024-07-05 10:26:32 +03:00
parent e22967accb
commit 40da1bbaa9
68 changed files with 17 additions and 56 deletions

View File

@ -3,8 +3,6 @@
#include "hack/utils/singleton.hpp"
#include "hack/utils/func_query.hpp"
#include "nlohmann/json.hpp"
int f(int a)
{
hack::log()("f implementatioln");

View File

@ -34,9 +34,11 @@ inc = []
deps = [
dependency('uuid'),
subproject('nlohmann_json').get_variable('nlohmann_json_dep'),
]
#############################################################
subdir('src')
subdir('tests')

View File

@ -6,7 +6,7 @@ run() {
command meson compile -C build
if [[ -z "$1" ]]; then
cd build
./bin/$PROJECT_NAME
./tests/$PROJECT_NAME
cd ..
else
meson test $1 -C build

View File

@ -1,42 +0,0 @@
project(
meson.current_source_dir().split('/').get(-1),
'cpp',
version : '1.2.0',
default_options : [
'warning_level=1',
'optimization=3',
'cpp_std=c++20',
])
add_project_arguments (
'-Wpedantic',
'-Wno-shadow',
'-Wno-unused-but-set-variable',
'-Wno-comment',
'-Wno-unused-parameter',
'-Wno-unused-value',
'-Wno-unused-header',
'-Wno-missing-field-initializers',
'-Wno-narrowing',
'-Wno-deprecated-enum-enum-conversion',
'-Wno-volatile',
'-Wno-format-security',
'-Wno-switch',
'-Wno-ignored-attributes',
'-Wno-unused-variable',
language: 'cpp'
)
#############################################################
args = []
inc = []
deps = [
subproject('nlohmann_json').get_variable('nlohmann_json_dep'),
subproject('hack').get_variable('hack_dep'),
]
#############################################################
subdir('bin')

@ -1 +0,0 @@
Subproject commit 04de2af292e52e6e48c1bffb08616dbf3f712c3b

View File

@ -1,7 +0,0 @@
[wrap-git]
url = https://gitcast.ru/chatlanin/hack.git
revision = master
[provide]
hack = hack_dep

View File

@ -11,7 +11,7 @@
#include "hack/logger/logger.hpp"
namespace hack::exception
namespace hack
{
using JSON = nlohmann::json;
@ -81,7 +81,7 @@ namespace hack::exception
return r;
}
JSON convert_to_json() override
JSON convert_to_json()
{
JSON j;
j["description"] = m_description;

11
tests/main.cpp Normal file
View File

@ -0,0 +1,11 @@
#include <array>
#include "hack/exception/exception.hpp"
auto main(int argc, char *argv[]) -> int
{
hack::exception ex;
ex.level("test_leve");
}

View File

@ -1,6 +1,6 @@
executable(
meson.project_name(),
'utils/main.cpp',
'main.cpp',
dependencies : deps,
cpp_args: args,
include_directories : inc