fix: assignment in type alias

This commit is contained in:
2025-01-05 21:18:55 +07:00
parent 47b5cc3880
commit 0aba4f6e69

View File

@@ -148,6 +148,7 @@ func ImplementModelAlias(modelName string, file *ast.File) {
Name: &ast.Ident{ Name: &ast.Ident{
Name: modelName, Name: modelName,
}, },
Assign: 1, // quick and dirty
Type: &ast.Ident{ Type: &ast.Ident{
Name: aliasTypeStandard, Name: aliasTypeStandard,
}, },
@@ -280,7 +281,7 @@ func ImplementMethod(file *ast.File, methodDecl *ast.FuncDecl, reimplement bool)
if reimplement || !methodImplemented { if reimplement || !methodImplemented {
file.Decls = append(decls, methodDecl) file.Decls = append(decls, methodDecl)
} }
return nil return nil
} }