Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ ci:

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v6.0.0
hooks:
- id: check-json
- id: check-merge-conflict
Expand All @@ -20,13 +20,13 @@ repos:
args: [--markdown-linebreak-ext=md]

- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.34.0
rev: v0.49.1
hooks:
- id: markdownlint
args: [-c, .markdownlint.yaml, --fix]

- repo: https://github.com/pre-commit/mirrors-prettier
rev: v3.0.0-alpha.9-for-vscode
rev: v4.0.0-alpha.8
hooks:
- id: prettier

Expand All @@ -36,18 +36,18 @@ repos:
# - id: yamllint

- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.9.0.2
rev: v0.11.0.1
hooks:
- id: shellcheck

- repo: https://github.com/scop/pre-commit-shfmt
rev: v3.6.0-2
rev: v3.13.1-1
hooks:
- id: shfmt
args: [-w, -s, -i=4]

- repo: https://github.com/tier4/pre-commit-hooks-ros
rev: v0.8.0
rev: v0.10.3
hooks:
- id: flake8-ros
- id: prettier-xacro
Expand All @@ -57,13 +57,13 @@ repos:
- id: sort-package-xml

- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v16.0.3
rev: v22.1.8
hooks:
- id: clang-format
types_or: [c++, c, cuda]

- repo: https://github.com/cpplint/cpplint
rev: 1.6.1
rev: 2.0.2
hooks:
- id: cpplint
args: [--quiet]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -325,8 +325,9 @@ class TildeSynchronizer
callback(msg0, msg1, msg2);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
}

template <
Expand All @@ -353,9 +354,10 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4));
}

template <
Expand Down Expand Up @@ -385,9 +387,10 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5));
}

template <
Expand Down Expand Up @@ -420,9 +423,10 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4, msg5);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6));
}

template <
Expand Down Expand Up @@ -459,9 +463,11 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6,
std::placeholders::_7));
}

template <
Expand Down Expand Up @@ -501,10 +507,11 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6, msg7);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8));
}

template <
Expand Down Expand Up @@ -547,10 +554,11 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6, msg7, msg8);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8, std::placeholders::_9));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8, std::placeholders::_9));
}

// non-const C callback&
Expand Down Expand Up @@ -596,8 +604,9 @@ class TildeSynchronizer
callback(msg0, msg1, msg2);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
}

template <
Expand All @@ -624,9 +633,10 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4));
}

template <
Expand Down Expand Up @@ -656,9 +666,10 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5));
}

template <
Expand Down Expand Up @@ -691,9 +702,10 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4, msg5);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6));
}

template <
Expand Down Expand Up @@ -730,9 +742,11 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6,
std::placeholders::_7));
}

template <
Expand Down Expand Up @@ -772,10 +786,11 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6, msg7);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8));
}

template <
Expand Down Expand Up @@ -818,10 +833,11 @@ class TildeSynchronizer

callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6, msg7, msg8);
};
return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8, std::placeholders::_9));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8, std::placeholders::_9));
}

// (const C& callback, T* t)
Expand Down Expand Up @@ -869,8 +885,9 @@ class TildeSynchronizer
bind_callback(msg0, msg1, msg2);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3));
}

template <
Expand Down Expand Up @@ -900,9 +917,10 @@ class TildeSynchronizer
bind_callback(msg0, msg1, msg2, msg3);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4));
}

template <
Expand Down Expand Up @@ -935,9 +953,10 @@ class TildeSynchronizer
bind_callback(msg0, msg1, msg2, msg3, msg4);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5));
}

template <
Expand Down Expand Up @@ -974,9 +993,10 @@ class TildeSynchronizer
bind_callback(msg0, msg1, msg2, msg3, msg4, msg5);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6));
}

template <
Expand Down Expand Up @@ -1016,9 +1036,11 @@ class TildeSynchronizer
bind_callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6,
std::placeholders::_7));
}

template <
Expand Down Expand Up @@ -1062,10 +1084,11 @@ class TildeSynchronizer
bind_callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6, msg7);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8));
}

template <
Expand Down Expand Up @@ -1113,10 +1136,11 @@ class TildeSynchronizer
bind_callback(msg0, msg1, msg2, msg3, msg4, msg5, msg6, msg7, msg8);
};

return sync_ptr_->registerCallback(std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8, std::placeholders::_9));
return sync_ptr_->registerCallback(
std::bind(
new_callback_lambda, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3,
std::placeholders::_4, std::placeholders::_5, std::placeholders::_6, std::placeholders::_7,
std::placeholders::_8, std::placeholders::_9));
}

// (C& callback, T* t)
Expand Down
13 changes: 8 additions & 5 deletions src/tilde_message_filters/src/sample_tilde_synchronizer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,10 @@ class SampleTildeSynchronizer2 : public tilde::TildeNode

// registerCallback(const C& callback) version:
// <- (const C&) can bind rvalue
sync_ptr_->registerCallback(std::bind(
&SampleTildeSynchronizer2::sub_callback, this, std::placeholders::_1, std::placeholders::_2));
sync_ptr_->registerCallback(
std::bind(
&SampleTildeSynchronizer2::sub_callback, this, std::placeholders::_1,
std::placeholders::_2));
}

private:
Expand Down Expand Up @@ -91,9 +93,10 @@ class SampleTildeSynchronizer3 : public tilde::TildeNode

// registerCallback(const C& callback) version:
// <- (const C&) can bind rvalue
sync_ptr_->registerCallback(std::bind(
&SampleTildeSynchronizer3::sub_callback, this, std::placeholders::_1, std::placeholders::_2,
std::placeholders::_3));
sync_ptr_->registerCallback(
std::bind(
&SampleTildeSynchronizer3::sub_callback, this, std::placeholders::_1, std::placeholders::_2,
std::placeholders::_3));
}

private:
Expand Down
Loading