[prev in list] [next in list] [prev in thread] [next in thread] 

List:       gentoo-dev
Subject:    [gentoo-dev] [PATCH] toolchain-funcs.eclass: Remove meaningless eval
From:       Michał Górny <mgorny () gentoo ! org>
Date:       2017-02-23 19:37:45
Message-ID: 20170223193745.26518-1-mgorny () gentoo ! org
[Download RAW message or body]

The 'eval' as used does not do anything. The function name is expanded
anyway.
---
 eclass/toolchain-funcs.eclass | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass
index 63f0d6b20912..3ca2e05ac74a 100644
--- a/eclass/toolchain-funcs.eclass
+++ b/eclass/toolchain-funcs.eclass
@@ -169,8 +169,8 @@ tc-getBUILD_PKG_CONFIG() { tc-getBUILD_PROG PKG_CONFIG pkg-config "$@"; }
 tc-export() {
 	local var
 	for var in "$@" ; do
-		[[ $(type -t tc-get${var}) != "function" ]] && die "tc-export: invalid export variable '${var}'"
-		eval tc-get${var} > /dev/null
+		[[ $(type -t "tc-get${var}") != "function" ]] && die "tc-export: invalid export variable '${var}'"
+		"tc-get${var}" > /dev/null
 	done
 }
 
-- 
2.11.1


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic