From 0fe5be352558c487e24724fca4c2cb9f53a724e6 Mon Sep 17 00:00:00 2001 From: Jacques Lucke Date: Thu, 18 Feb 2021 12:40:27 +0100 Subject: Cleanup: return const reference instead of copy There isn't really a reason for why this has to return a copy of the data instead of a reference. --- source/blender/nodes/NOD_geometry_exec.hh | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'source/blender/nodes/NOD_geometry_exec.hh') diff --git a/source/blender/nodes/NOD_geometry_exec.hh b/source/blender/nodes/NOD_geometry_exec.hh index d5fd3ff0abb..e648d77337b 100644 --- a/source/blender/nodes/NOD_geometry_exec.hh +++ b/source/blender/nodes/NOD_geometry_exec.hh @@ -133,11 +133,8 @@ class GeoNodeExecParams { /** * Get the input value for the input socket with the given identifier. - * - * This makes a copy of the value, which is fine for most types but should be avoided for - * geometry sets. */ - template T get_input(StringRef identifier) const + template const T &get_input(StringRef identifier) const { #ifdef DEBUG this->check_extract_input(identifier, &CPPType::get()); -- cgit v1.2.3