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

Allow multiline conditionals #51

Conversation

stpierre
Copy link
Contributor

Terraform allows a ternary to be split among multiple lines, with comments interspersed. For instance:

count = (
  var.tgw_name == "" ?  # put a comment here for fun
  0 :
  var.number_of_az
)

Previously, the grammar only supported single-line ternary expressions.

@aoskotsky-amplify
Copy link
Member

Nice catch @stpierre. I'll try to get this merged soon. Thanks!

@aoskotsky-amplify aoskotsky-amplify merged commit 0aa13e2 into amplify-education:master Dec 25, 2020
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