Nest all namespaces
The compiler supports this now. We can type less going forward.
No functional changes.
Signed-off-by: Stephan Pleines <pleines.stephan@gmail.com>
Change-Id: I29d6fa4f9aacc0e381f1a7637294db0392466995
diff --git a/y2022_bot3/control_loops/drivetrain/drivetrain_base.cc b/y2022_bot3/control_loops/drivetrain/drivetrain_base.cc
index a97e0dd..dc89588 100644
--- a/y2022_bot3/control_loops/drivetrain/drivetrain_base.cc
+++ b/y2022_bot3/control_loops/drivetrain/drivetrain_base.cc
@@ -14,9 +14,7 @@
namespace chrono = ::std::chrono;
-namespace y2022_bot3 {
-namespace control_loops {
-namespace drivetrain {
+namespace y2022_bot3::control_loops::drivetrain {
using ::frc971::constants::ShifterHallEffect;
@@ -66,6 +64,4 @@
return kDrivetrainConfig;
};
-} // namespace drivetrain
-} // namespace control_loops
-} // namespace y2022_bot3
+} // namespace y2022_bot3::control_loops::drivetrain
diff --git a/y2022_bot3/control_loops/superstructure/superstructure.cc b/y2022_bot3/control_loops/superstructure/superstructure.cc
index f701907..3dfa74c 100644
--- a/y2022_bot3/control_loops/superstructure/superstructure.cc
+++ b/y2022_bot3/control_loops/superstructure/superstructure.cc
@@ -4,9 +4,7 @@
#include "aos/flatbuffer_merge.h"
#include "frc971/zeroing/wrap.h"
-namespace y2022_bot3 {
-namespace control_loops {
-namespace superstructure {
+namespace y2022_bot3::control_loops::superstructure {
using frc971::control_loops::AbsoluteEncoderProfiledJointStatus;
using frc971::control_loops::PotAndAbsoluteEncoderProfiledJointStatus;
@@ -89,6 +87,4 @@
(void)status->Send(status_builder.Finish());
}
-} // namespace superstructure
-} // namespace control_loops
-} // namespace y2022_bot3
+} // namespace y2022_bot3::control_loops::superstructure
diff --git a/y2022_bot3/control_loops/superstructure/superstructure_lib_test.cc b/y2022_bot3/control_loops/superstructure/superstructure_lib_test.cc
index 614bc08..493d2f5 100644
--- a/y2022_bot3/control_loops/superstructure/superstructure_lib_test.cc
+++ b/y2022_bot3/control_loops/superstructure/superstructure_lib_test.cc
@@ -15,10 +15,7 @@
DEFINE_string(output_folder, "",
"If set, logs all channels to the provided logfile.");
-namespace y2022_bot3 {
-namespace control_loops {
-namespace superstructure {
-namespace testing {
+namespace y2022_bot3::control_loops::superstructure::testing {
namespace chrono = std::chrono;
using ::aos::monotonic_clock;
@@ -472,7 +469,4 @@
TestRoller(0.0);
}
-} // namespace testing
-} // namespace superstructure
-} // namespace control_loops
-} // namespace y2022_bot3
\ No newline at end of file
+} // namespace y2022_bot3::control_loops::superstructure::testing