about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp
diff options
context:
space:
mode:
authorEdd Barrett <vext01@gmail.com>2020-08-26 17:39:43 +0100
committerEdd Barrett <vext01@gmail.com>2020-09-05 19:59:30 +0100
commit8af85fa1f73428888730b05e48291c73897dd44d (patch)
tree41e808138c7cec35e7690bb5a39b3e563b60c2d0 /compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp
parent7d289aeade481c03d42e7f6d31bc6b64a73cfa45 (diff)
downloadrust-8af85fa1f73428888730b05e48291c73897dd44d.tar.gz
rust-8af85fa1f73428888730b05e48291c73897dd44d.zip
Improve the documentation of `filter()` and `filter_map()`.
I believe the documentation is currently a little misleading.

For example, in the docs for `filter()`:

> If the closure returns `false`, it will try again, and call the closure on
> the next element, seeing if it passes the test.

This kind of implies that if the closure returns true then we *don't* "try
again" and no further elements are considered. In actuality that's not the
case, every element is tried regardless of what happened with the previous
element.

This change tries to clarify that by removing the uses of "try again"
altogether.
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions