Skip to content

Commit dc55793

Browse files
use char pointer to fix uninitialized constants downstream (#71)
1 parent bca301a commit dc55793

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

include/spark_dsg/scene_graph_types.h

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -79,21 +79,21 @@ struct LayerKey {
7979
//! @brief Common layer names
8080
struct DsgLayers {
8181
//! Pre-Object node layer (static)
82-
inline const static std::string SEGMENTS = "SEGMENTS";
82+
inline constexpr static const char* SEGMENTS = "SEGMENTS";
8383
//! Object node layer (static)
84-
inline const static std::string OBJECTS = "OBJECTS";
84+
inline constexpr static const char* OBJECTS = "OBJECTS";
8585
//! Agents layer (dynamic)
86-
inline const static std::string AGENTS = "AGENTS";
86+
inline constexpr static const char* AGENTS = "AGENTS";
8787
//! Places node layer
88-
inline const static std::string PLACES = "PLACES";
88+
inline constexpr static const char* PLACES = "PLACES";
8989
//! Mesh (2D) Places node layer
90-
inline const static std::string MESH_PLACES = "MESH_PLACES";
90+
inline constexpr static const char* MESH_PLACES = "MESH_PLACES";
9191
//! Traversability node layer
92-
inline const static std::string TRAVERSABILITY = "TRAVERSABILITY";
92+
inline constexpr static const char* TRAVERSABILITY = "TRAVERSABILITY";
9393
//! Room node layer
94-
inline const static std::string ROOMS = "ROOMS";
94+
inline constexpr static const char* ROOMS = "ROOMS";
9595
//! Building node layer
96-
inline const static std::string BUILDINGS = "BUILDINGS";
96+
inline constexpr static const char* BUILDINGS = "BUILDINGS";
9797

9898
//! Get default layer ID for each layer name
9999
static std::optional<LayerKey> nameToLayerId(const std::string& name);

0 commit comments

Comments
 (0)