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: prevent enum members to have unexpected structures #3240

Merged
merged 1 commit into from
Jan 20, 2023

Conversation

trocher
Copy link
Contributor

@trocher trocher commented Jan 19, 2023

What I did

How I did it

Added checks that the fields of an enum must be Expr statements with values that are Name

How to verify it

See tests

Commit message

fix: prevent enum members to have unexpected structures

Description for the changelog

Enforce enum members to be simple names

Cute Animal Picture

Put a link to a cute animal picture inside the parenthesis-->

@fubuloubu fubuloubu enabled auto-merge (squash) January 19, 2023 22:59
@fubuloubu fubuloubu disabled auto-merge January 19, 2023 22:59
@fubuloubu
Copy link
Member

I'll let @charles-cooper set auto-merge and/or approve this one

@codecov-commenter
Copy link

codecov-commenter commented Jan 19, 2023

Codecov Report

Merging #3240 (851bf55) into master (d4f04c6) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #3240   +/-   ##
=======================================
  Coverage   88.94%   88.94%           
=======================================
  Files          84       84           
  Lines       10588    10590    +2     
  Branches     2208     2209    +1     
=======================================
+ Hits         9417     9419    +2     
  Misses        760      760           
  Partials      411      411           
Impacted Files Coverage Δ
vyper/semantics/types/user.py 85.57% <100.00%> (+0.09%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@charles-cooper charles-cooper merged commit de3ec9f into vyperlang:master Jan 20, 2023
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.

enum members can have unexpected structure
4 participants