From df623ee370ea795e4284f9a4becb0c8ec4ce8ec2 Mon Sep 17 00:00:00 2001 From: Jeremy Nimmer Date: Tue, 31 Dec 2024 08:17:44 -0800 Subject: [PATCH] Remove unncessary includes Including iostream means introducing the static (global) constructors and destructors for std::cin, std::cerr, and std::cout. That extra init and fini code is undesirable when those streams are not actually used. Signed-off-by: Jeremy Nimmer --- include/sdf/Error.hh | 4 ++-- include/sdf/Exception.hh | 2 +- src/Console.cc | 1 + src/Element.cc | 1 + src/FrameSemantics.cc | 1 + src/SDF.cc | 3 ++- 6 files changed, 8 insertions(+), 4 deletions(-) diff --git a/include/sdf/Error.hh b/include/sdf/Error.hh index 9664cc850..beaae0318 100644 --- a/include/sdf/Error.hh +++ b/include/sdf/Error.hh @@ -17,9 +17,9 @@ #ifndef SDF_ERROR_HH_ #define SDF_ERROR_HH_ -#include -#include #include +#include +#include #include #include #include "sdf/Console.hh" diff --git a/include/sdf/Exception.hh b/include/sdf/Exception.hh index 303482017..a5258c37f 100644 --- a/include/sdf/Exception.hh +++ b/include/sdf/Exception.hh @@ -19,8 +19,8 @@ #define SDF_EXCEPTION_HH_ #include -#include #include +#include #include #include diff --git a/src/Console.cc b/src/Console.cc index 558f10d87..1ac350895 100644 --- a/src/Console.cc +++ b/src/Console.cc @@ -16,6 +16,7 @@ */ #include +#include #include #include #include diff --git a/src/Element.cc b/src/Element.cc index fd8950d7f..b31826703 100644 --- a/src/Element.cc +++ b/src/Element.cc @@ -16,6 +16,7 @@ */ #include +#include #include #include diff --git a/src/FrameSemantics.cc b/src/FrameSemantics.cc index 40df3c4c4..ee6e56739 100644 --- a/src/FrameSemantics.cc +++ b/src/FrameSemantics.cc @@ -15,6 +15,7 @@ * */ #include +#include #include #include #include diff --git a/src/SDF.cc b/src/SDF.cc index d9fa57dbd..bafd80ab8 100644 --- a/src/SDF.cc +++ b/src/SDF.cc @@ -17,10 +17,11 @@ #include #include -#include #include +#include #include #include +#include #include #include