Skip to content

Commit 767bf76

Browse files
authored
Fix tidy reports (#140)
* added some tidy errors * restored src/beman/execution/CMakeLists.txt * fix a formatting issue * changed not by ! to avoid a formatting issue
1 parent d78336d commit 767bf76

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

Makefile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ CXX_FLAGS ?= -g
3434
SANITIZER ?= default
3535
SOURCEDIR = $(CURDIR)
3636
BUILDROOT = build
37-
BUILD = $(BUILDROOT)/$(SANITIZER)
37+
SYSTEM = $(shell uname -s)
38+
BUILD = $(BUILDROOT)/$(SYSTEM)/$(SANITIZER)
3839
EXAMPLE = beman.execution.examples.stop_token
3940
CMAKE_CXX_COMPILER=$(COMPILER)
4041

@@ -113,6 +114,7 @@ check:
113114
done | tsort > /dev/null
114115

115116
build/$(SANITIZER)/compile_commands.json: $(SANITIZER)
117+
116118
clang-tidy: $(BUILD)/compile_commands.json
117119
run-clang-tidy -p $(BUILD) tests examples
118120

@@ -138,7 +140,7 @@ clean-doc:
138140
$(RM) -r docs/html docs/latex
139141

140142
clean: clean-doc
141-
$(RM) -r $(BUILD)
143+
cmake --build $(BUILD) --target clean
142144
$(RM) mkerr olderr *~
143145

144146
distclean: clean

include/beman/execution/detail/sched_attrs.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,8 @@ class sched_attrs {
2424

2525
public:
2626
template <typename S>
27-
explicit sched_attrs(S s) : sched(::std::move(s)) {}
27+
requires(!::std::same_as<sched_attrs, ::std::remove_cvref_t<S>>)
28+
explicit sched_attrs(S&& s) : sched(::std::forward<S>(s)) {}
2829

2930
template <typename Tag>
3031
auto query(const ::beman::execution::get_completion_scheduler_t<Tag>&) const noexcept {

0 commit comments

Comments
 (0)