Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 1D0FE200D63 for ; Wed, 6 Dec 2017 13:13:06 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 1C120160BFD; Wed, 6 Dec 2017 12:13:06 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 6BDDD160C08 for ; Wed, 6 Dec 2017 13:13:05 +0100 (CET) Received: (qmail 76250 invoked by uid 500); 6 Dec 2017 12:13:04 -0000 Mailing-List: contact commits-help@groovy.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@groovy.apache.org Delivered-To: mailing list commits@groovy.apache.org Received: (qmail 76234 invoked by uid 99); 6 Dec 2017 12:13:04 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 06 Dec 2017 12:13:04 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id C4A0BF17D5; Wed, 6 Dec 2017 12:13:02 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: sunlan@apache.org To: commits@groovy.apache.org Date: Wed, 06 Dec 2017 12:13:02 -0000 Message-Id: <7555345409db40aca70684e6785f88dd@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [1/4] groovy git commit: Minor refactoring archived-at: Wed, 06 Dec 2017 12:13:06 -0000 Repository: groovy Updated Branches: refs/heads/GROOVY_2_4_X 1c312a50f -> e7ee5ede0 Minor refactoring (cherry picked from commit 53b2a07) Project: http://git-wip-us.apache.org/repos/asf/groovy/repo Commit: http://git-wip-us.apache.org/repos/asf/groovy/commit/e988957c Tree: http://git-wip-us.apache.org/repos/asf/groovy/tree/e988957c Diff: http://git-wip-us.apache.org/repos/asf/groovy/diff/e988957c Branch: refs/heads/GROOVY_2_4_X Commit: e988957c0718bd4edd5df3f3c323821a5dd5c5b4 Parents: 29592e1 Author: sunlan Authored: Sat Dec 2 15:04:56 2017 +0800 Committer: sunlan Committed: Sat Dec 2 16:24:29 2017 +0800 ---------------------------------------------------------------------- src/main/groovy/grape/GrabAnnotationTransformation.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/groovy/blob/e988957c/src/main/groovy/grape/GrabAnnotationTransformation.java ---------------------------------------------------------------------- diff --git a/src/main/groovy/grape/GrabAnnotationTransformation.java b/src/main/groovy/grape/GrabAnnotationTransformation.java index ad76ea2..0bccbbe 100644 --- a/src/main/groovy/grape/GrabAnnotationTransformation.java +++ b/src/main/groovy/grape/GrabAnnotationTransformation.java @@ -552,8 +552,9 @@ public class GrabAnnotationTransformation extends ClassCodeVisitorSupport implem // assume gradle syntax // see: http://www.gradle.org/latest/docs/userguide/dependency_management.html#sec:how_to_declare_your_dependencies Map parts = GrapeUtil.getIvyParts(allstr); - for (String key : parts.keySet()) { - String value = parts.get(key).toString(); + for (Map.Entry entry : parts.entrySet()) { + String key = entry.getKey(); + String value = entry.getValue().toString(); if (!key.equals("version") || !value.equals("*") || !exclude) { node.addMember(key, constX(value)); }