From 78df5ef4293937504ff9d237fd3ac41c4528d997 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Eric=20Meadows-J=C3=B6nsson?= Date: Fri, 25 Sep 2015 17:02:56 +0200 Subject: [PATCH] Only use MapSet on Elixir 1.2+ --- .travis.yml | 1 + lib/hex/resolver.ex | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 38c7c011d..68c7c4e6e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -17,6 +17,7 @@ script: env: matrix: - ELIXIRVERSION=v1.0.5 + - ELIXIRVERSION=v1.1.0 - ELIXIRVERSION=master notifications: recipients: diff --git a/lib/hex/resolver.ex b/lib/hex/resolver.ex index b776552b8..fda3fc55f 100644 --- a/lib/hex/resolver.ex +++ b/lib/hex/resolver.ex @@ -280,7 +280,7 @@ defmodule Hex.Resolver do defp requirement(nil), do: ">= 0.0.0" defp requirement(req), do: req.source - if Version.compare("1.1.0", System.version) == :gt do + if Version.compare("1.2.0", System.version) == :gt do defp new_set(enum), do: Enum.into(enum, HashSet.new) else defp new_set(enum), do: Enum.into(enum, MapSet.new)