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

propagate the error from parsing enum variant to the parser and emit out #105098

Merged
merged 1 commit into from
Dec 6, 2022

Commits on Dec 2, 2022

  1. While parsing enum variant, the error message always disappear

    Because the error message that emit out is from main error of parser
    The information of enum variant disappears while parsing enum variant with error
    We only check the syntax of expecting token, i.e, in case rust-lang#103869
    It will error it without telling the message that this error is from pasring enum variant.
    Propagate the sub-error from parsing enum variant to the main error of parser by chaining it with map_err
    Check the sub-error before emitting the main error of parser and attach it.
    Fix rust-lang#103869
    Yiming Lei committed Dec 2, 2022
    Configuration menu
    Copy the full SHA
    0e19fb9 View commit details
    Browse the repository at this point in the history