From 804c009a874009ba0b00a5c0307c1ae60ab73b93 Mon Sep 17 00:00:00 2001 From: Elizabeth Mattijsen Date: Thu, 1 Mar 2018 13:14:57 +0100 Subject: [PATCH] =?UTF-8?q?Make=20sub=20infix:=C2=AB=3D>=C2=BB=20a=20multi?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/core/Pair.pm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/core/Pair.pm b/src/core/Pair.pm index ac8d0f0fac8..81ad830fa1a 100644 --- a/src/core/Pair.pm +++ b/src/core/Pair.pm @@ -132,9 +132,8 @@ multi sub infix:(Pair:D \a, Pair:D \b) { (a.key cmp b.key) || (a.value cmp b.value) } -sub infix:«=>»(Mu $key, Mu \value) is pure { - Pair.new($key, value) -} +proto sub infix:«=>»(|) is pure {*} +multi sub infix:«=>»(Mu $key, Mu \value) { Pair.new($key, value) } proto sub pair(|) is pure {*} multi sub pair(Mu $key, \value) { Pair.new($key, value) }