-
Notifications
You must be signed in to change notification settings - Fork 742
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
Add a resource<'type@version'>
utility type
#12591
Conversation
Test this change out locally with the following install scripts (Action run 7427793137) VSCode
Azure CLI
|
Test Results 74 files - 25 74 suites - 25 26m 34s ⏱️ - 21m 8s For more details on these failures, see this check. Results for commit d4b213e. ± Comparison against base commit 86e8f18. ♻️ This comment has been updated with latest results. |
fe4e37c
to
b3fc5c7
Compare
src/Bicep.Core.Samples/Files/baselines/ResourceDerivedTypes_LF/main.formatted.bicep
Outdated
Show resolved
Hide resolved
src/Bicep.Core.Samples/Files/baselines/InvalidResourceDerivedTypes_LF/main.bicep
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
Partially address #9229
This PR adds a new ambient type symbol name
resource
(in thesys
namespace) and kind of syntax for using types that accept parameters (resource<'type@version'>
). This new kind of syntax is called aParameterizedTypeInstantiation
node because, following C#'s example, each appearance of the syntax is expected to produce a type symbol and an IR expression that can be used in place of a concrete type clause.This PR does not implement the logic to use the type of a specific property within a resource body, as that is turning out to be fairly complex, and this PR is already large and pretty dense.
Microsoft Reviewers: Open in CodeFlow