From 204652acab6677fce966e8e7600d24967fe8c267 Mon Sep 17 00:00:00 2001 From: Tim Holy Date: Mon, 20 Apr 2015 05:39:33 -0500 Subject: [PATCH] Add `eachindex` to README --- README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/README.md b/README.md index a893bcc1926c3..3d4719e2200de 100644 --- a/README.md +++ b/README.md @@ -50,6 +50,10 @@ Currently, the `@compat` macro supports the following syntaxes: * For all unsigned integer types to their equivalents with uppercase `I`. [#8907](https://github.com/JuliaLang/julia/pull/8907) +## New functions + +* `eachindex`, as in `for i in eachindex(A)`, can be used in julia 0.3. This is the recommended way to iterate over each index in an `AbstractArray`. On julia 0.3 `eachindex` just returns `1:length(A)`, but in julia 0.4 it can return a more sophisticated iterator. + ## Renamed functions * `itrunc`, `iround`, `iceil`, `ifloor` are now accessed via `trunc(T, x)`, etc. [#9133](https://github.com/JuliaLang/julia/pull/9133)