From eb949646771401349d44daa63a8ccc098c308cf5 Mon Sep 17 00:00:00 2001 From: elvis Date: Sun, 17 Aug 2025 03:32:21 +0200 Subject: [PATCH] More explicatory errors --- src/rsprocess/assert/rsassert.rs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/rsprocess/assert/rsassert.rs b/src/rsprocess/assert/rsassert.rs index 560795e..6052a60 100644 --- a/src/rsprocess/assert/rsassert.rs +++ b/src/rsprocess/assert/rsassert.rs @@ -85,7 +85,9 @@ impl RSassert { AssertionTypes::System | AssertionTypes::Context => Ok(()), - AssertionTypes::NoType | + AssertionTypes::NoType => + Err(format!("No return type, at least one return statement \ + required.")), AssertionTypes::RangeInteger | AssertionTypes::RangeSet | AssertionTypes::RangeNeighbours => @@ -197,7 +199,9 @@ impl RSassert { AssertionTypes::System | AssertionTypes::Context => Ok(()), - AssertionTypes::NoType | + AssertionTypes::NoType => + Err(format!("No return type, at least one return statement \ + required.")), AssertionTypes::RangeInteger | AssertionTypes::RangeSet | AssertionTypes::RangeNeighbours =>