Skip to content

Work around #8256, do not fail the task, just return None #8278

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

Closed
wants to merge 1 commit into from
Closed

Work around #8256, do not fail the task, just return None #8278

wants to merge 1 commit into from

Conversation

emberian
Copy link
Member

@emberian emberian commented Aug 4, 2013

No description provided.

@brson
Copy link
Contributor

brson commented Aug 4, 2013

Does span_to_snippet always fail? Are you sure this isn't a rustdoc bug?

At the least, please put some comments in explaining this is a workaround and linking to the issue.

@brson
Copy link
Contributor

brson commented Aug 4, 2013

As an aside, resolve looking for "::" in the code snippet in order to do diagnostics (and diagnostics of questionable value and correctness) is pretty crummy.

@emberian
Copy link
Member Author

emberian commented Aug 4, 2013

It does not always fail. I'm not 100% sure it's not a rustdoc bug, but I'm just giving it a span I get from the AST for an expr, and I wouldn't think it'd ever fail for a span I get from the AST.

@emberian
Copy link
Member Author

emberian commented Aug 4, 2013

Yes, that error message was my first PR, it was the only way I could figure out how to do it at the time. Blame whoever r+'d it 😉

bors added a commit that referenced this pull request Aug 6, 2013
@bors bors closed this Aug 6, 2013
flip1995 pushed a commit to flip1995/rust that referenced this pull request Jan 27, 2022
…elf-ty, r=xFrednet

`needless_lifetimes`: ignore lifetimes in explicit self types

changelog: false positive fix: [`needless_lifetimes`] no longer lints lifetimes in explicit self types

They're not currently elidable (rust-lang#69064)

Fixes rust-lang#7296
bors pushed a commit to rust-lang-ci/rust that referenced this pull request Jan 28, 2025
…ng#13992)

Commit 9ef6e21 introduced a check to
ensure that Clippy doesn't consider a lifetime present in an explicit
self types as being the default for an elided output lifetime. For
example, elision did not work in the case like:

```rust
  fn func(self: &Rc<Self>, &str) -> &str { … }
```

Since Rust 1.81.0, the lifetime in the self type is now considered the
default for elision. Elision should then be suggested when appropriate.

changelog: [`needless_lifetimes`]: suggest elision of lifetimes present
in explicit self types as well

r? @Alexendoo
because of rust-lang#8278
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants