Skip to content

Commit

Permalink
Let resource names that conflict with extra types
Browse files Browse the repository at this point in the history
  • Loading branch information
iwahbe committed Nov 3, 2022
1 parent 9122140 commit 3f71e8b
Show file tree
Hide file tree
Showing 8 changed files with 668 additions and 1 deletion.
@@ -0,0 +1,4 @@
changes:
- type: fix
scope: sdkgen/go
description: Allow resource names that conflict with additional types.
4 changes: 4 additions & 0 deletions pkg/codegen/go/gen.go
Expand Up @@ -3223,6 +3223,10 @@ func generatePackageContextMap(tool string, pkg *schema.Package, goInfo GoPackag
names = append(names, cgstrings.Camel(rawResourceName(r))+suffix+"State")
names = append(names, "Get"+rawResourceName(r)+suffix)
}
if goInfo.GenerateResourceContainerTypes && !r.IsProvider {
names = append(names, rawResourceName(r)+suffix+"Array")
names = append(names, rawResourceName(r)+suffix+"Map")
}
return names
}

Expand Down
Expand Up @@ -3,6 +3,10 @@
"repro/doc.go",
"repro/foo.go",
"repro/init.go",
"repro/overlap/consumer.go",
"repro/overlap/init.go",
"repro/overlap/someType.go",
"repro/overlap/someTypeMap.go",
"repro/provider.go",
"repro/pulumi-plugin.json",
"repro/pulumiTypes.go",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 3f71e8b

Please sign in to comment.