mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-20 20:13:33 +08:00
Explicit constructors
This commit is contained in:
@@ -74,7 +74,7 @@ protected:
|
||||
INode& node_;
|
||||
uint32_t failure_count_;
|
||||
|
||||
GenericSubscriberBase(INode& node)
|
||||
explicit GenericSubscriberBase(INode& node)
|
||||
: node_(node)
|
||||
, failure_count_(0)
|
||||
{ }
|
||||
|
||||
@@ -37,7 +37,7 @@ class UAVCAN_EXPORT GlobalDataTypeRegistry : Noncopyable
|
||||
struct EntryInsertionComparator
|
||||
{
|
||||
const DataTypeID id;
|
||||
EntryInsertionComparator(Entry* dtd) : id(dtd->descriptor.getID()) { }
|
||||
explicit EntryInsertionComparator(Entry* dtd) : id(dtd->descriptor.getID()) { }
|
||||
bool operator()(const Entry* entry) const
|
||||
{
|
||||
assert(entry);
|
||||
|
||||
@@ -75,7 +75,7 @@ protected:
|
||||
MonotonicDuration request_timeout_;
|
||||
bool pending_;
|
||||
|
||||
ServiceClientBase(INode& node)
|
||||
explicit ServiceClientBase(INode& node)
|
||||
: DeadlineHandler(node.getScheduler())
|
||||
, request_timeout_(getDefaultRequestTimeout())
|
||||
, pending_(false)
|
||||
|
||||
Reference in New Issue
Block a user