[v1] test: span: Use intended variable
diff mbox series

Message ID 20241203151251.794657-1-pobrn@protonmail.com
State New
Headers show
Series
  • [v1] test: span: Use intended variable
Related show

Commit Message

Barnabás Pőcze Dec. 3, 2024, 3:12 p.m. UTC
It appears that the original intention was to use it in these
particular constructor tests: the variable is otherwise unused,
and `Span<const int>{ v }` is already tested.

Signed-off-by: Barnabás Pőcze <pobrn@protonmail.com>
---
 test/span.cpp | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Laurent Pinchart Dec. 3, 2024, 9:40 p.m. UTC | #1
Hi Barnabás,

Thank you for the patch.

On Tue, Dec 03, 2024 at 03:12:53PM +0000, Barnabás Pőcze wrote:
> It appears that the original intention was to use it in these
> particular constructor tests: the variable is otherwise unused,
> and `Span<const int>{ v }` is already tested.
> 
> Signed-off-by: Barnabás Pőcze <pobrn@protonmail.com>

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

> ---
>  test/span.cpp | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/test/span.cpp b/test/span.cpp
> index 5452967d..4b9f3279 100644
> --- a/test/span.cpp
> +++ b/test/span.cpp
> @@ -143,9 +143,9 @@ protected:
>  		Span<const int>{ v };
>  		/* Span<float>{ v }; */
>  
> -		Span<const int>{ v };
> -		/* Span<int>{ v }; */
> -		/* Span<const float>{ v }; */
> +		Span<const int>{ cv };
> +		/* Span<int>{ cv }; */
> +		/* Span<const float>{ cv }; */
>  
>  		Span<int> dynamicSpan{ i };
>  		Span<int>{ dynamicSpan };

Patch
diff mbox series

diff --git a/test/span.cpp b/test/span.cpp
index 5452967d..4b9f3279 100644
--- a/test/span.cpp
+++ b/test/span.cpp
@@ -143,9 +143,9 @@  protected:
 		Span<const int>{ v };
 		/* Span<float>{ v }; */
 
-		Span<const int>{ v };
-		/* Span<int>{ v }; */
-		/* Span<const float>{ v }; */
+		Span<const int>{ cv };
+		/* Span<int>{ cv }; */
+		/* Span<const float>{ cv }; */
 
 		Span<int> dynamicSpan{ i };
 		Span<int>{ dynamicSpan };