Skip to content

Commit

Permalink
fix some style
Browse files Browse the repository at this point in the history
  • Loading branch information
oathdruid committed Aug 23, 2024
1 parent a97a3f6 commit e40027b
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 11 deletions.
6 changes: 3 additions & 3 deletions src/babylon/anyflow/builtin/expression.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -522,9 +522,9 @@ struct ConditionalExpression

struct NonConditionalExpression
: public grammar<const char*, space_type, ::std::tuple<size_t, size_t>()> {
NonConditionalExpression(
expression::Option& input_option,
::std::unordered_map<::std::string, size_t>& input_variable_indexes) noexcept
NonConditionalExpression(expression::Option& input_option,
::std::unordered_map<::std::string, size_t>&
input_variable_indexes) noexcept
: base_type(start, "non_conditional_expression"),
option(input_option),
variable_indexes(input_variable_indexes) {
Expand Down
6 changes: 4 additions & 2 deletions src/babylon/executor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,10 @@ template <typename C, typename... Args>
inline int Executor::submit(C&& callable, Args&&... args) noexcept {
typedef typename ::std::decay<C>::type DC;
MoveOnlyFunction<void(void)> function {::std::bind(
[](DC& captured_callable, typename ::std::decay<Args>::type&... captured_args) {
normalize(::std::move(captured_callable))(::std::move(captured_args)...);
[](DC& captured_callable,
typename ::std::decay<Args>::type&... captured_args) {
normalize(::std::move(captured_callable))(
::std::move(captured_args)...);
},
uncomposable_bind_argument(::std::forward<C>(callable)),
uncomposable_bind_argument(::std::forward<Args>(args))...)};
Expand Down
11 changes: 6 additions & 5 deletions src/babylon/logging/log_entry.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,12 @@ class LogEntry {
::std::vector<struct ::iovec>& iov) noexcept;

private:
static void pages_append_to_iovec(char** pages, size_t size, size_t page_size,
::std::vector<struct ::iovec>& iov) noexcept;
static void page_table_append_to_iovec(PageTable& page_table, size_t size,
size_t page_size,
::std::vector<struct ::iovec>& iov) noexcept;
static void pages_append_to_iovec(
char** pages, size_t size, size_t page_size,
::std::vector<struct ::iovec>& iov) noexcept;
static void page_table_append_to_iovec(
PageTable& page_table, size_t size, size_t page_size,
::std::vector<struct ::iovec>& iov) noexcept;

public:
// 元信息只记录一个总长度,总长度确定后
Expand Down
3 changes: 2 additions & 1 deletion src/babylon/move_only_function.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,8 @@ inline UncomposableBindArgument<T>::UncomposableBindArgument(T&& input_value)
: value(::std::move(input_value)) {}

template <typename T>
inline UncomposableBindArgument<T>::UncomposableBindArgument(const T& input_value)
inline UncomposableBindArgument<T>::UncomposableBindArgument(
const T& input_value)
: value(input_value) {}

template <typename T>
Expand Down

0 comments on commit e40027b

Please sign in to comment.