From b06593c82b190fca398590dcc457709b84f99695 Mon Sep 17 00:00:00 2001 From: utkarshanand140 Date: Fri, 23 Feb 2024 19:16:26 +0530 Subject: [PATCH] Modified gitignore to avoid tracking .DS_Store MacOS files and also replacing unecessary strings with characters types for faster compilations --- .gitignore | 3 +++ moveit_core/collision_detection/src/collision_common.cpp | 2 +- moveit_core/collision_detection/src/collision_tools.cpp | 2 +- .../src/default_collisions_widget.cpp | 2 +- .../moveit_setup_srdf_plugins/src/group_meta_config.cpp | 2 +- 5 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 82f4adc900..b3e2aebd8c 100644 --- a/.gitignore +++ b/.gitignore @@ -76,3 +76,6 @@ _autosummary # source dependencies (see moveit2.repos) moveit_msgs moveit_resources + +# ignore macos generated files +.DS_Store diff --git a/moveit_core/collision_detection/src/collision_common.cpp b/moveit_core/collision_detection/src/collision_common.cpp index d869e61f31..a07381434d 100644 --- a/moveit_core/collision_detection/src/collision_common.cpp +++ b/moveit_core/collision_detection/src/collision_common.cpp @@ -67,7 +67,7 @@ void CollisionResult::print() const for (const auto& contact : contacts) { RCLCPP_DEBUG_STREAM_THROTTLE(getLogger(), clock, LOG_THROTTLE_PERIOD, - "\t" << contact.first.first << ", " << contact.first.second); + '\t' << contact.first.first << ", " << contact.first.second); } #pragma GCC diagnostic pop } diff --git a/moveit_core/collision_detection/src/collision_tools.cpp b/moveit_core/collision_detection/src/collision_tools.cpp index eaef0dbc8b..003beb3677 100644 --- a/moveit_core/collision_detection/src/collision_tools.cpp +++ b/moveit_core/collision_detection/src/collision_tools.cpp @@ -106,7 +106,7 @@ void getCollisionMarkersFromContacts(visualization_msgs::msg::MarkerArray& arr, { for (const auto& contact : collision.second) { - std::string ns_name = contact.body_name_1 + "=" + contact.body_name_2; + std::string ns_name = contact.body_name_1 + '=' + contact.body_name_2; if (ns_counts.find(ns_name) == ns_counts.end()) { ns_counts[ns_name] = 0; diff --git a/moveit_setup_assistant/moveit_setup_srdf_plugins/src/default_collisions_widget.cpp b/moveit_setup_assistant/moveit_setup_srdf_plugins/src/default_collisions_widget.cpp index 6873789126..d93e659e19 100644 --- a/moveit_setup_assistant/moveit_setup_srdf_plugins/src/default_collisions_widget.cpp +++ b/moveit_setup_assistant/moveit_setup_srdf_plugins/src/default_collisions_widget.cpp @@ -124,7 +124,7 @@ void DefaultCollisionsWidget::onInit() fraction_spinbox_ = new QSpinBox(this); fraction_spinbox_->setRange(1, 100); fraction_spinbox_->setValue(95); - fraction_spinbox_->setSuffix("%"); + fraction_spinbox_->setSuffix('%'); buttons_layout->addWidget(fraction_spinbox_); // Generate Button diff --git a/moveit_setup_assistant/moveit_setup_srdf_plugins/src/group_meta_config.cpp b/moveit_setup_assistant/moveit_setup_srdf_plugins/src/group_meta_config.cpp index 3080d49851..0669412b9f 100644 --- a/moveit_setup_assistant/moveit_setup_srdf_plugins/src/group_meta_config.cpp +++ b/moveit_setup_assistant/moveit_setup_srdf_plugins/src/group_meta_config.cpp @@ -185,7 +185,7 @@ void GroupMetaConfig::collectVariables(std::vector& variables) // add a linebreak if we have more than one entry if (!kinematics_parameters_files_block.empty()) - kinematics_parameters_files_block += "\n"; + kinematics_parameters_files_block += '\n'; std::string line = " ";