From 4c392c30dbe36f12158bb609438be646f9ab6b3d Mon Sep 17 00:00:00 2001 From: Smilenator Date: Thu, 5 Jul 2018 16:46:22 +0300 Subject: [PATCH] core: fix func TxDifference fix a typo in func comment; change named return to unnamed as there's explicit return in the body --- core/types/transaction.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/types/transaction.go b/core/types/transaction.go index b824a77f61..65616f298d 100644 --- a/core/types/transaction.go +++ b/core/types/transaction.go @@ -266,9 +266,9 @@ func (s Transactions) GetRlp(i int) []byte { return enc } -// TxDifference returns a new set t which is the difference between a to b. -func TxDifference(a, b Transactions) (keep Transactions) { - keep = make(Transactions, 0, len(a)) +// TxDifference returns a new set which is the difference between a to b. +func TxDifference(a, b Transactions) Transactions { + keep := make(Transactions, 0, len(a)) remove := make(map[common.Hash]struct{}) for _, tx := range b {