Skip to content

Commit

Permalink
address review comment: restore argumentMarker method
Browse files Browse the repository at this point in the history
  • Loading branch information
scgkiran committed Dec 2, 2024
1 parent 3f61589 commit 402419f
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions extensions/simple_extension.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ type TypeVariation struct {

type FuncParameter interface {
toTypeString() string
argumentMarker() // unexported marker method
GetTypeExpression() types.FuncDefArgType
}

Expand All @@ -72,6 +73,8 @@ func (EnumArg) toTypeString() string {
return EnumTypeString
}

func (v EnumArg) argumentMarker() {}

func (v EnumArg) GetTypeExpression() types.FuncDefArgType {
return &types.EnumType{Name: v.Name, Options: v.Options}

Check warning on line 79 in extensions/simple_extension.go

View check run for this annotation

Codecov / codecov/patch

extensions/simple_extension.go#L78-L79

Added lines #L78 - L79 were not covered by tests
}
Expand All @@ -87,6 +90,8 @@ func (v ValueArg) toTypeString() string {
return v.Value.ValueType.ShortString()
}

func (v ValueArg) argumentMarker() {}

func (v ValueArg) GetTypeExpression() types.FuncDefArgType {
return v.Value.ValueType
}
Expand All @@ -99,6 +104,8 @@ type TypeArg struct {

func (TypeArg) toTypeString() string { return "type" }

func (v TypeArg) argumentMarker() {}

func (v TypeArg) GetTypeExpression() types.FuncDefArgType {
return v.Type.ValueType

Check warning on line 110 in extensions/simple_extension.go

View check run for this annotation

Codecov / codecov/patch

extensions/simple_extension.go#L109-L110

Added lines #L109 - L110 were not covered by tests
}
Expand Down

0 comments on commit 402419f

Please sign in to comment.