From cbe26bd665963f1ed2240efb3e0309914f6a3388 Mon Sep 17 00:00:00 2001 From: nihui <171016+nihui@users.noreply.github.com> Date: Fri, 21 Feb 2025 11:03:52 +0000 Subject: [PATCH] apply code-format changes --- src/expression.cpp | 41 ++++++++++++++++++++++++---------------- tests/test_paramdict.cpp | 1 - 2 files changed, 25 insertions(+), 17 deletions(-) diff --git a/src/expression.cpp b/src/expression.cpp index 60d23339a4b..fe299edd4a7 100644 --- a/src/expression.cpp +++ b/src/expression.cpp @@ -63,20 +63,20 @@ int count_expression_blobs(const std::string& expr) std::vector eval_list_expression(const std::string& expr, const std::vector& blobs) { -// /(0w,2),*(0h,2),0c + // /(0w,2),*(0h,2),0c -// split by , ( ) -// -// / -// 0w -// 2 -// ------------------- -// * -// 0h -// 2 -// ------------------- -// 0c -// ------------------- + // split by , ( ) + // + // / + // 0w + // 2 + // ------------------- + // * + // 0h + // 2 + // ------------------- + // 0c + // ------------------- // split by , ( ) @@ -124,9 +124,18 @@ std::vector eval_list_expression(const std::string& expr, const std::vector float f; }; - typed_value() : type(0), i(0) {} - typed_value(int _i) : type(0), i(_i) {} - typed_value(float _f) : type(1), f(_f) {} + typed_value() + : type(0), i(0) + { + } + typed_value(int _i) + : type(0), i(_i) + { + } + typed_value(float _f) + : type(1), f(_f) + { + } int to_int() { diff --git a/tests/test_paramdict.cpp b/tests/test_paramdict.cpp index 2d82d14d6b0..7d101d650d8 100644 --- a/tests/test_paramdict.cpp +++ b/tests/test_paramdict.cpp @@ -679,7 +679,6 @@ static int test_paramdict_6() int main() { - std::vector blobs(2); blobs[0].w = 100; blobs[0].h = 200;