Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename Range to AbstractRange #23570

Merged
merged 7 commits into from
Sep 8, 2017
Merged

Rename Range to AbstractRange #23570

merged 7 commits into from
Sep 8, 2017

Conversation

nalimilan
Copy link
Member

Fixes #21901.

@ararslan ararslan added domain:collections Data structures holding multiple items, e.g. sets kind:deprecation This change introduces or involves a deprecation labels Sep 3, 2017
@nalimilan
Copy link
Member Author

OK to merge? This tends to accumulate conflicts quite fast.

Copy link
Sponsor Member

@mbauman mbauman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor comments about some of the doc changes. Bravo for digging into the editor config files. 👍

@@ -172,7 +172,7 @@ first(a::AbstractArray) = a[first(eachindex(a))]
first(coll)

Get the first element of an iterable collection. Returns the start point of a
Copy link
Sponsor Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pedant: a -> an

@@ -409,7 +409,7 @@ julia> for i = 1:5
5
```

Here the `1:5` is a `Range` object, representing the sequence of numbers 1, 2, 3, 4, 5. The `for`
Here the `1:5` is an `AbstractRange` object, representing the sequence of numbers 1, 2, 3, 4, 5. The `for`
Copy link
Sponsor Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It'd be clearer to just say it's a UnitRange or maybe even just "a range" (lowercase).

@@ -348,7 +348,7 @@ indices and can be converted to such by [`to_indices`](@ref):
2. An array of scalar indices. This includes:
* Vectors and multidimensional arrays of integers
* Empty arrays like `[]`, which select no elements
* `Range`s of the form `a:c` or `a:b:c`, which select contiguous or strided subsections from `a` to `c` (inclusive)
* `AbstractRange`s of the form `a:c` or `a:b:c`, which select contiguous or strided subsections from `a` to `c` (inclusive)
Copy link
Sponsor Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd simply say: "Ranges like a:c…" Making this more jargon-y implies a distinction that doesn't exist.

@nalimilan
Copy link
Member Author

Thanks for the review. Indeed the systematic replacement of Range to AbstractRange made some sentences quite weird. Should be fixed now.

@mbauman mbauman merged commit 02fba85 into master Sep 8, 2017
@mbauman mbauman deleted the nl/abstractrange branch September 8, 2017 14:44
Bachibouzouk added a commit to Bachibouzouk/Mbo.jl that referenced this pull request Jul 22, 2024
-Range renamed AbstractRange
JuliaLang/julia#23570

-squeeze renamed dropdims

-immutable renamed struct
JuliaLang/julia#20418
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
domain:collections Data structures holding multiple items, e.g. sets kind:deprecation This change introduces or involves a deprecation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants