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

Restrict parsing of bare union/struct to field types #88815

Closed
wants to merge 4 commits into from

Commits on Sep 10, 2021

  1. Restrict parsing of bare union/struct to field types

    Do not unconditionally parse bare types everywhere, only parse them if
    they are in a field type, and try them when recovering a misparse
    everywhere else, using them only if they are successfuly fully parsed.
    
    Fix rust-lang#88583.
    estebank committed Sep 10, 2021
    Configuration menu
    Copy the full SHA
    70ff7ff View commit details
    Browse the repository at this point in the history
  2. remove pprint-check for type X = union {}

    `type X = union {}` isn't supported. Trying to pretty print it will emit a
    `delay_as_bug` error to be emitted because a later stage should have
    triggered under normal circumstances.
    estebank committed Sep 10, 2021
    Configuration menu
    Copy the full SHA
    0e989bd View commit details
    Browse the repository at this point in the history
  3. Simplify parse_ty_recover_anon_adt

    It didn't need to be that complex, the `look_ahead` check was enough, as
    braces aren't allowed after neither `static` or `type`.
    estebank committed Sep 10, 2021
    Configuration menu
    Copy the full SHA
    2f7b3d0 View commit details
    Browse the repository at this point in the history
  4. make comment more accurate

    estebank committed Sep 10, 2021
    Configuration menu
    Copy the full SHA
    191ad9e View commit details
    Browse the repository at this point in the history