Skip to content

Commit 2b86a8c

Browse files
authored
no warnings (#37)
1 parent b40eab7 commit 2b86a8c

File tree

6 files changed

+7
-19
lines changed

6 files changed

+7
-19
lines changed

.bazelrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,6 @@ build:windows --host_platform=//bazel/platforms:windows
1111
build:linux --platforms=//bazel/platforms:linux
1212
build:linux --extra_toolchains=@llvm_toolchain//:cc-toolchain-x86_64-linux
1313

14+
build:no-warnings --per_file_copt=//.*@-Werror
15+
1416
try-import %workspace%/user.bazelrc

.github/workflows/ci.bazelrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,5 @@ test --test_output=errors
1212
# Allows tests to run bazelisk-in-bazel, since this is the cache folder used
1313
test --test_env=XDG_CACHE_HOME
1414

15+
build:linux --config=no-warnings
16+

ecsact/entt/detail/system_execution_context.hh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -375,8 +375,6 @@ struct system_execution_context : system_execution_context_base {
375375

376376
using associations = typename caps_info::associations;
377377

378-
auto other_entt_entity_id = info.get_entt_entity_id(other_entity);
379-
380378
ecsact_system_execution_context* return_context = nullptr;
381379

382380
constexpr auto assoc_count = mp_size<associations>::value;

ecsact/entt/system_view.hh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,6 @@ auto association_view(::entt::registry& registry) {
8080
using assoc_marker_component =
8181
association<typename Assoc::component_type, Assoc::field_offset>;
8282
using extra_get_types = ::ecsact::mp_list<assoc_marker_component>;
83-
using view_type = view_from_system_capabilities_type<Assoc, extra_get_types>;
8483

8584
return view_from_system_capabilities<Assoc, extra_get_types>(registry);
8685
}

ecsact/entt/trivial_system_impl.hh

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,17 +25,12 @@ constexpr bool is_trivial_system() {
2525
using readonly_components = typename caps_info::readonly_components;
2626
using readwrite_components = typename caps_info::readwrite_components;
2727
using writeonly_components = typename caps_info::writeonly_components;
28-
using include_components = typename caps_info::include_components;
29-
using exclude_components = typename caps_info::exclude_components;
3028
using adds_components = typename caps_info::adds_components;
3129
using removes_components = typename caps_info::removes_components;
3230
using adds_tag_components = mp_filter<std::is_empty, adds_components>;
33-
using remove_tag_components = mp_filter<std::is_empty, removes_components>;
34-
using adds_non_tag_components = mp_filter<is_not_empty, adds_components>;
3531

3632
const bool can_add = !mp_empty<adds_components>::value;
3733
const bool can_remove = !mp_empty<removes_components>::value;
38-
const bool can_add_non_tag = !mp_empty<adds_non_tag_components>::value;
3934

4035
const bool can_only_add_tag = mp_size<adds_tag_components>::value ==
4136
mp_size<adds_components>::value;

runtime/test/runtime_test.cc

Lines changed: 3 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -278,16 +278,6 @@ TEST(Core, RemoveComponent) {
278278
EXPECT_FALSE(ecsact_has_component(reg_id, entity, comp_id));
279279
}
280280

281-
static void dynamic_impl(ecsact_system_execution_context* ctx) {
282-
using runtime_test::ComponentA;
283-
284-
auto comp_id = static_cast<ecsact_component_like_id>(ComponentA::id);
285-
ComponentA comp;
286-
ecsact_system_execution_context_get(ctx, comp_id, &comp);
287-
comp.a += 2;
288-
ecsact_system_execution_context_update(ctx, comp_id, &comp);
289-
}
290-
291281
TEST(Core, TrivialRemoveEvent) {
292282
auto reg_id = ecsact_create_registry("TrivialRemoveEvent");
293283
auto entity = ecsact_create_entity(reg_id);
@@ -647,7 +637,9 @@ TEST(Core, AssociationEntityCorrectness) {
647637
++attack_damage_exec_count;
648638
ecsact::execution_context ctx{cctx};
649639
ASSERT_TRUE(attacker_entities.contains(ctx.entity()));
650-
auto target_ctx = ctx.other(ctx.get<runtime_test::Attacking>().target);
640+
641+
// Santity check - no exception
642+
ctx.other(ctx.get<runtime_test::Attacking>().target);
651643
}
652644
);
653645

0 commit comments

Comments
 (0)