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

fix: add redeclare variable error message (#1987) #2002

Merged
merged 2 commits into from
Jul 27, 2021

Conversation

HerrCai0907
Copy link
Member

  • add a diagnostic message: Cannot redeclare block-scoped variable '{0}', when variants scope re-declare, throw out following message instead of abort:

    ERROR TS2451: Cannot redeclare block-scoped variable 'a'

     let a = a + b;
     ~~~~~~~~~~~~~
    

    in assembly/index.ts(4,3)

  • add my name and email in NOTICE

  • I've read the contributing guidelines

src/flow.ts Outdated Show resolved Hide resolved
src/flow.ts Outdated Show resolved Hide resolved
Copy link
Member Author

@HerrCai0907 HerrCai0907 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add error message of re-declare variable

@MaxGraey
Copy link
Member

@HerrCai0907 it seems your email desn't associate with github account

@MaxGraey
Copy link
Member

You can use <77575210+HerrCai0907@users.noreply.github.com> btw

@MaxGraey MaxGraey requested a review from dcodeIO July 24, 2021 15:33
@MaxGraey MaxGraey changed the title feat: add redeclare variable error message (#1987) fix: add redeclare variable error message (#1987) Jul 24, 2021
@MaxGraey MaxGraey merged commit 935b865 into AssemblyScript:main Jul 27, 2021
@MaxGraey
Copy link
Member

Thanks!

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.

2 participants