cpplint: add filter whitespace/forcolon (#29582)

whitespace/forcolon
This commit is contained in:
Dean Lee
2023-08-24 13:46:02 +08:00
committed by GitHub
parent 3719be8b76
commit ac93902983
4 changed files with 5 additions and 5 deletions
+1 -1
View File
@@ -64,7 +64,7 @@ repos:
- --linelength=240
# https://google.github.io/styleguide/cppguide.html
# relevant rules are whitelisted, see all options with: cpplint --filter=
- --filter=-build,-legal,-readability,-runtime,-whitespace,+build/forward_decl,+build/include_what_you_use,+build/deprecated,+whitespace/line_length,+whitespace/empty_if_body,+whitespace/empty_loop_body,+whitespace/empty_conditional_body,+whitespace/parens,+whitespace/semicolon,+readability/braces
- --filter=-build,-legal,-readability,-runtime,-whitespace,+build/forward_decl,+build/include_what_you_use,+build/deprecated,+whitespace/line_length,+whitespace/empty_if_body,+whitespace/empty_loop_body,+whitespace/empty_conditional_body,+whitespace/forcolon,+whitespace/parens,+whitespace/semicolon,+readability/braces
- repo: local
hooks:
- id: test_translations
+1 -1
View File
@@ -61,7 +61,7 @@ QMapbox::CoordinatesCollections coordinate_to_collection(const QMapbox::Coordina
QMapbox::CoordinatesCollections capnp_coordinate_list_to_collection(const capnp::List<cereal::NavRoute::Coordinate>::Reader& coordinate_list) {
QMapbox::Coordinates coordinates;
for (auto const &c: coordinate_list) {
for (auto const &c : coordinate_list) {
coordinates.push_back({c.getLatitude(), c.getLongitude()});
}
return {QMapbox::CoordinatesCollection{coordinates}};
+1 -1
View File
@@ -156,7 +156,7 @@ PrimeAdWidget::PrimeAdWidget(QWidget* parent) : QFrame(parent) {
main_layout->addSpacing(30);
QVector<QString> bullets = {tr("Remote access"), tr("24/7 LTE connectivity"), tr("1 year of drive storage"), tr("Turn-by-turn navigation")};
for (auto &b: bullets) {
for (auto &b : bullets) {
const QString check = "<b><font color='#465BEA'>✓</font></b> ";
QLabel *l = new QLabel(check + b);
l->setAlignment(Qt::AlignLeft);
+2 -2
View File
@@ -98,7 +98,7 @@ int handle_encoder_msg(LoggerdState *s, Message *msg, std::string &name, struct
re.marked_ready_to_rotate = false;
// we are in this segment now, process any queued messages before this one
if (!re.q.empty()) {
for (auto &qmsg: re.q) {
for (auto &qmsg : re.q) {
bytes_count += handle_encoder_msg(s, qmsg, name, re, encoder_info);
}
re.q.clear();
@@ -233,7 +233,7 @@ void loggerd_thread() {
std::map<std::string, EncoderInfo> encoder_infos_dict;
for (const auto &cam : cameras_logged) {
for (const auto &encoder_info: cam.encoder_infos) {
for (const auto &encoder_info : cam.encoder_infos) {
encoder_infos_dict[encoder_info.publish_name] = encoder_info;
s.max_waiting++;
}