Skip to content

Commit 0fe11b8

Browse files
authored
Fix macOS/Clang debug warnings/errors (#185)
* [#24607] Fix macOS/Clang debug warnings/errors Signed-off-by: danipiza <dpizarrogallego@gmail.com> * [#24607] Applied uncrustify Signed-off-by: danipiza <dpizarrogallego@gmail.com> --------- Signed-off-by: danipiza <dpizarrogallego@gmail.com>
1 parent 2d1ed3f commit 0fe11b8

4 files changed

Lines changed: 27 additions & 18 deletions

File tree

ddspipe_core/src/cpp/types/dds/TopicQoS.cpp

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,16 @@ namespace ddspipe {
2525
namespace core {
2626
namespace types {
2727

28+
constexpr const DurabilityKind TopicQoS::DEFAULT_DURABILITY_QOS;
29+
constexpr const ReliabilityKind TopicQoS::DEFAULT_RELIABILITY_QOS;
30+
constexpr const OwnershipQosPolicyKind TopicQoS::DEFAULT_OWNERSHIP_QOS;
31+
constexpr const bool TopicQoS::DEFAULT_USE_PARTITIONS;
32+
constexpr const HistoryDepthType TopicQoS::DEFAULT_HISTORY_DEPTH;
33+
constexpr const bool TopicQoS::DEFAULT_KEYED;
34+
constexpr const float TopicQoS::DEFAULT_MAX_TX_RATE;
35+
constexpr const float TopicQoS::DEFAULT_MAX_RX_RATE;
36+
constexpr const unsigned int TopicQoS::DEFAULT_DOWNSAMPLING;
37+
2838
utils::Fuzzy<TopicQoS> TopicQoS::default_topic_qos{};
2939

3040
TopicQoS::TopicQoS()
@@ -239,18 +249,17 @@ std::ostream& operator <<(
239249
std::ostream& os,
240250
const TopicQoS& qos)
241251
{
242-
os <<
243-
"TopicQoS{" <<
244-
"durability(" << qos.durability_qos << ")" <<
245-
";reliability(" << qos.reliability_qos << ")" <<
246-
";ownership(" << qos.ownership_qos << ")" <<
247-
(qos.has_partitions() ? ";partitions" : "") <<
248-
(qos.keyed ? ";keyed" : "") <<
249-
";depth(" << qos.history_depth << ")" <<
250-
";max_tx_rate(" << qos.max_tx_rate << ")" <<
251-
";max_rx_rate(" << qos.max_rx_rate << ")" <<
252-
";downsampling(" << qos.downsampling << ")" <<
253-
"}";
252+
os << "TopicQoS{"
253+
<< "durability(" << qos.durability_qos << ")"
254+
<< ";reliability(" << qos.reliability_qos << ")"
255+
<< ";ownership(" << qos.ownership_qos << ")"
256+
<< (qos.has_partitions() ? ";partitions" : "")
257+
<< (qos.keyed ? ";keyed" : "")
258+
<< ";depth(" << qos.history_depth << ")"
259+
<< ";max_tx_rate(" << qos.max_tx_rate << ")"
260+
<< ";max_rx_rate(" << qos.max_rx_rate << ")"
261+
<< ";downsampling(" << qos.downsampling << ")"
262+
<< "}";
254263

255264
return os;
256265
}

ddspipe_participants/include/ddspipe_participants/reader/dds/CommonReader.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -85,19 +85,19 @@ class CommonReader : public BaseReader, public fastdds::dds::DataReaderListener,
8585
/////////////////////////
8686

8787
virtual void on_data_available(
88-
fastdds::dds::DataReader* reader);
88+
fastdds::dds::DataReader* reader) override;
8989

9090
virtual void on_sample_lost(
9191
fastdds::dds::DataReader* reader,
92-
const fastdds::dds::SampleLostStatus& status);
92+
const fastdds::dds::SampleLostStatus& status) override;
9393

9494
virtual void on_requested_incompatible_qos(
9595
fastdds::dds::DataReader* reader,
96-
const fastdds::dds::RequestedIncompatibleQosStatus& status);
96+
const fastdds::dds::RequestedIncompatibleQosStatus& status) override;
9797

9898
virtual void on_inconsistent_topic(
9999
fastdds::dds::Topic* topic,
100-
fastdds::dds::InconsistentTopicStatus status);
100+
fastdds::dds::InconsistentTopicStatus status) override;
101101

102102
protected:
103103

ddspipe_participants/include/ddspipe_participants/reader/rtps/CommonReader.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ class CommonReader : public BaseReader, public fastdds::rtps::ReaderListener
282282
const core::types::DdsTopic& topic) noexcept;
283283

284284
//! Topic Description to create RTPS Reader
285-
fastdds::rtps::TopicDescription reckon_topic_description_(
285+
static fastdds::rtps::TopicDescription reckon_topic_description_(
286286
const core::types::DdsTopic& topic) noexcept;
287287

288288
//! Reader QoS to create RTPS Reader

ddspipe_participants/include/ddspipe_participants/writer/rtps/CommonWriter.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ class CommonWriter : public BaseWriter, public fastdds::rtps::WriterListener
259259
const core::types::DdsTopic& topic) noexcept;
260260

261261
//! Topic Description to create RTPS Writer
262-
fastdds::rtps::TopicDescription reckon_topic_description_(
262+
static fastdds::rtps::TopicDescription reckon_topic_description_(
263263
const core::types::DdsTopic& topic) noexcept;
264264

265265
//! QoS for RTPS Writer

0 commit comments

Comments
 (0)