Skip to content

Bring back suggestion for splitting <- in a comparison #62632

Closed

Description

@varkor
fn main() {
    if x<-1 {
    }
}

produces:

error: expected `{`, found `<-`

It would be nice if it produced a suggestion to split it up:

if x < -1 {

(This used to happen, but was broken in a previous change.)

Activity

  1. added
    E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
    A-diagnosticsArea: Messages for errors, warnings, and lints
    on Jul 12, 2019
  2. agnxy commented on Jul 13, 2019

    @agnxy
    Contributor

    Hi @varkor I'd like to try this one. Just found the removed suggestion.

  3. agnxy commented on Jul 13, 2019

    @agnxy
    Contributor

    @rustbot claim

  4. JohnTitor commented on Jul 13, 2019

    @JohnTitor
  5. added
    C-enhancementCategory: An issue proposing an enhancement or a PR with one.
    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.
    on Jul 14, 2019
  6. iluuu1994 commented on Aug 11, 2019

    @iluuu1994
    Contributor

    @agnxy It doesn't look like you're still working on this. Is it ok if I take over?

  7. added a commit that references this issue on Aug 12, 2019
    b503f8e
  8. agnxy commented on Aug 12, 2019

    @agnxy
    Contributor

    @iluuu1994 Sure. Thanks for your help.

  9. added 2 commits that reference this issue on Aug 13, 2019
    86ed4ce
    87ec7b4
  10. added a commit that references this issue on Aug 14, 2019
    2781889
  11. added 2 commits that reference this issue on Aug 14, 2019
    69848fe
    c824839
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

A-diagnosticsArea: Messages for errors, warnings, and lintsC-enhancementCategory: An issue proposing an enhancement or a PR with one.E-easyCall for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions