From 829199f91a9bff85f2a69221fa0f9d55fe1f3c86 Mon Sep 17 00:00:00 2001 From: "A.M. Rowsell" Date: Sat, 21 Feb 2026 16:38:26 -0500 Subject: [PATCH] chore: run through 'clang-tidy' with '-fix' --- src/irc/types.h | 27 ++++++++++++++------------- 1 file changed, 14 insertions(+), 13 deletions(-) diff --git a/src/irc/types.h b/src/irc/types.h index 457950c..f52db8d 100644 --- a/src/irc/types.h +++ b/src/irc/types.h @@ -8,6 +8,7 @@ #include #include #include +#include #include #include @@ -206,41 +207,41 @@ public: // Constructor implementations inline LambdaNode::LambdaNode(uint32_t a, std::shared_ptr b, uint32_t l) - : arity(a), body(b), line(l) {} + : arity(a), body(std::move(b)), line(l) {} inline AppNode::AppNode(std::shared_ptr f, std::shared_ptr a, uint32_t l) - : func(f), arg(a), line(l) {} + : func(std::move(f)), arg(std::move(a)), line(l) {} inline BinaryOpNode::BinaryOpNode(BinaryOp o, std::shared_ptr l, std::shared_ptr r, uint32_t ln) - : op(o), left(l), right(r), line(ln) {} + : op(o), left(std::move(l)), right(std::move(r)), line(ln) {} inline UnaryOpNode::UnaryOpNode(UnaryOp o, std::shared_ptr operand, uint32_t l) - : op(o), operand(operand), line(l) {} + : op(o), operand(std::move(operand)), line(l) {} inline SelectNode::SelectNode(std::shared_ptr e, std::shared_ptr a, uint32_t l) - : expr(e), attr(a), line(l) {} + : expr(std::move(e)), attr(std::move(a)), line(l) {} inline HasAttrNode::HasAttrNode(std::shared_ptr e, std::shared_ptr a, uint32_t l) - : expr(e), attr(a), line(l) {} + : expr(std::move(e)), attr(std::move(a)), line(l) {} inline WithNode::WithNode(std::shared_ptr a, std::shared_ptr b, uint32_t l) - : attrs(a), body(b), line(l) {} + : attrs(std::move(a)), body(std::move(b)), line(l) {} inline IfNode::IfNode(std::shared_ptr c, std::shared_ptr t, std::shared_ptr e, uint32_t l) - : cond(c), then_branch(t), else_branch(e), line(l) {} + : cond(std::move(c)), then_branch(std::move(t)), else_branch(std::move(e)), line(l) {} -inline LetNode::LetNode(std::shared_ptr b, uint32_t l) : body(b), line(l) {} +inline LetNode::LetNode(std::shared_ptr b, uint32_t l) : body(std::move(b)), line(l) {} -inline LetRecNode::LetRecNode(std::shared_ptr b, uint32_t l) : body(b), line(l) {} +inline LetRecNode::LetRecNode(std::shared_ptr b, uint32_t l) : body(std::move(b)), line(l) {} inline AssertNode::AssertNode(std::shared_ptr c, std::shared_ptr b, uint32_t l) - : cond(c), body(b), line(l) {} + : cond(std::move(c)), body(std::move(b)), line(l) {} -inline ThunkNode::ThunkNode(std::shared_ptr e, uint32_t l) : expr(e), line(l) {} +inline ThunkNode::ThunkNode(std::shared_ptr e, uint32_t l) : expr(std::move(e)), line(l) {} -inline ForceNode::ForceNode(std::shared_ptr e, uint32_t l) : expr(e), line(l) {} +inline ForceNode::ForceNode(std::shared_ptr e, uint32_t l) : expr(std::move(e)), line(l) {} struct SourceFile { std::string path;