From 9004756a6a019c1cced018aa7ab91619bbf0cfe1 Mon Sep 17 00:00:00 2001 From: "Steven G. Johnson" Date: Wed, 18 Nov 2015 15:07:53 -0500 Subject: [PATCH] =?UTF-8?q?improve=20deprecation=20warning=20for=20non-int?= =?UTF-8?q?eger=20indexing:=20suggest=20replacing=20i/j=20with=20i=C3=B7j?= =?UTF-8?q?=20(see=20#10458)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- base/deprecated.jl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/deprecated.jl b/base/deprecated.jl index 4ee8e8347c93aa..b0f44e243fe84f 100644 --- a/base/deprecated.jl +++ b/base/deprecated.jl @@ -444,7 +444,7 @@ end to_index_nodep(i::Real) = convert(Int,i)::Int @noinline function to_index(i::Real) - depwarn("indexing with non Integer Reals is deprecated", :to_index) + depwarn("Indexing with non-Integer Reals is deprecated. It may be that your index arose from an integer division with i/j, in which case you should consider using i÷j or div(i,j) instead, equivalent to round(Int, i/j, RoundToZero).", :to_index) to_index_nodep(i) end