From 9042747f53f9f33cf2d1995d37a090080a800d77 Mon Sep 17 00:00:00 2001 From: Mathias Lang Date: Thu, 21 Dec 2023 13:53:08 +0100 Subject: [PATCH] Deprecate string-as-version PackageManager.getBestPackage overload Because using a typed Version or VersionRange is better than using a string and we want to encourage version validation to be done earlier than later. --- source/dub/packagemanager.d | 1 + 1 file changed, 1 insertion(+) diff --git a/source/dub/packagemanager.d b/source/dub/packagemanager.d index a5d68613a..0ba9d3f60 100644 --- a/source/dub/packagemanager.d +++ b/source/dub/packagemanager.d @@ -440,6 +440,7 @@ class PackageManager { } /// Ditto + deprecated("Use the overload that accepts a `Version` or a `VersionRange`") Package getBestPackage(string name, string range) { return this.getBestPackage(name, VersionRange.fromString(range));