@@ -132,10 +132,10 @@ struct ScalarAttributeValue final : public AttributeValue {
132132 ValueType& value () {
133133 return value_;
134134 }
135- virtual Ptr clone () const override {
135+ Ptr clone () const override {
136136 return std::make_unique<ScalarAttributeValue>(name, value_);
137137 }
138- virtual AttributeKind kind () const override {
138+ AttributeKind kind () const override {
139139 return Kind;
140140 }
141141
@@ -147,14 +147,14 @@ template <typename T, AttributeKind Kind>
147147struct VectorAttributeValue final : public AttributeValue {
148148 using ConstructorType = const std::vector<T>&&;
149149 using ValueType = std::vector<T>;
150- VectorAttributeValue (Symbol name, ConstructorType value_) : AttributeValue(name), value_(std::move(value_)) {}
150+ VectorAttributeValue (Symbol name, ValueType value_) : AttributeValue(name), value_(std::move(value_)) {}
151151 ValueType& value () {
152152 return value_;
153153 }
154- virtual AttributeKind kind () const override {
154+ AttributeKind kind () const override {
155155 return Kind;
156156 }
157- virtual std::unique_ptr<AttributeValue> clone () const override {
157+ std::unique_ptr<AttributeValue> clone () const override {
158158 return std::make_unique<VectorAttributeValue>(name, ValueType (value_));
159159 }
160160
@@ -181,7 +181,7 @@ using TypeProtosAttr = VectorAttributeValue<TypeProto, AttributeKind::tps>;
181181// we return Derived* pointers because Nodes are normally held as pointers.
182182template <typename Derived>
183183struct Attributes {
184- Attributes () {}
184+ Attributes () = default ;
185185 void copyAttributes (const Attributes& rhs) {
186186 values_.clear ();
187187 values_.reserve (rhs.values_ .size ());
@@ -375,7 +375,7 @@ struct Value final {
375375 Graph* owningGraph ();
376376 const Graph* owningGraph () const ;
377377 // TODO: make this more const correct
378- const use_list uses () const ;
378+ use_list uses () const ;
379379
380380 // Replaces all uses of this node with 'newValue'.
381381 //
@@ -839,7 +839,7 @@ class OpSetID final {
839839 // Default Domain Constructor
840840 explicit OpSetID (const int64_t version) : domain_(" " ), version_(version) {}
841841
842- explicit OpSetID (const std::string& domain, int64_t version) : domain_(domain), version_(version) {}
842+ explicit OpSetID (std::string domain, int64_t version) : domain_(std::move( domain) ), version_(version) {}
843843
844844 // target must be in the form "<domain>&<version>"
845845 std::string toString () const {
@@ -1425,7 +1425,7 @@ inline const_graph_node_list_iterator Node::reverseIterator() const {
14251425// nodes in subgraph are also included.
14261426// This method is usually used to check whether it is
14271427// safe to delete a Value.
1428- inline const use_list Value::uses () const {
1428+ inline use_list Value::uses () const {
14291429 use_list all_uses = uses_in_current_graph_;
14301430 owningGraph ()->forEachNode ([this , &all_uses](const Node* node) {
14311431 if (node->owningGraph () == this ->owningGraph ()) {
0 commit comments