8000 Use StrEnum · cortea-ai/sqlc-gen-python@ea89ec1 · GitHub
[go: up one dir, main page]

Skip to content {"props":{"docsUrl":"https://docs.github.com/get-started/accessibility/keyboard-shortcuts"}}

Commit ea89ec1

Browse files
committed
Use StrEnum
1 parent 0fa045c commit ea89ec1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

internal/gen.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -954,7 +954,7 @@ func buildModelsTree(ctx *pyTmplCtx, i *importer) *pyast.Node {
954954
Name: e.Name,
955955
Bases: []*pyast.Node{
956956
poet.Name("str"),
957-
poet.Attribute(poet.Name("enum"), "Enum"),
957+
poet.Attribute(poet.Name("enum"), "StrEnum"),
958958
},
959959
}
960960
if e.Comment != "" {

internal/printer/printer_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ func TestPrinter(t *testing.T) {
6060
Name: &ast.Name{Id: "enum"},
6161
},
6262
},
63-
Attr: "Enum",
63+
Attr: "StrEnum",
6464
},
6565
},
6666
},

0 commit comments

Comments
 (0)
0