-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use the type name to help resolve name clashes (#107)
- Loading branch information
Showing
8 changed files
with
103 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
### Improvements | ||
|
||
- Better conflict resolution for conflicting source names. They'll now use the objects type name to help build a unique name. | ||
|
||
### Bug Fixes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
pkg/convert/testdata/programs/name_conflict_renames/main.tf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
resource "renames_resource" "a_thing" { | ||
a_number = 1 | ||
a_resource { | ||
inner_string = "hello" | ||
} | ||
} | ||
|
||
data "renames_data_source" "a_thing" { | ||
a_number = 2 | ||
a_resource { | ||
inner_string = "hello" | ||
} | ||
} |
14 changes: 14 additions & 0 deletions
14
pkg/convert/testdata/programs/name_conflict_renames/pcl/main.pp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
resource "aThingResource" "renames:index/index:resource" { | ||
__logicalName = "a_thing" | ||
theNumber = 1 | ||
theResource = { | ||
theInnerString = "hello" | ||
} | ||
} | ||
|
||
aThing = invoke("renames:index/index:dataSource", { | ||
theNumber = 2 | ||
theResource = { | ||
theInnerString = "hello" | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters