Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
goccy committed Oct 24, 2024
1 parent eec8086 commit 3789771
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 12 deletions.
4 changes: 0 additions & 4 deletions cdt/cdt.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,6 @@ func (l *Link) getWasm() *wasm.DictLink {
return l.wasm
}

func toDictLinkWasm(v *Link) *wasm.DictLink {
return v.wasm
}

type Method struct {
wasm *wasm.DictMethod
}
Expand Down
7 changes: 0 additions & 7 deletions cgraph/cgraph.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,6 @@ func toGraph(v *wasm.Graph) *Graph {
return &Graph{wasm: v}
}

func toGraphWasm(v *Graph) *wasm.Graph {
if v == nil {
return nil
}
return v.wasm
}

func (g *Graph) getWasm() *wasm.Graph {
if g == nil {
return nil
Expand Down
9 changes: 8 additions & 1 deletion cgraph/link.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,12 @@ func toDictWasm(*cdt.Dict) *wasm.Dict
//go:linkname toDictLink github.com/goccy/go-graphviz/cdt.toLink
func toDictLink(*wasm.DictLink) *cdt.Link

//go:linkname toDictLinkWasm github.com/goccy/go-graphviz/cdt.toDictLinkWasm
//go:linkname toDictLinkWasm github.com/goccy/go-graphviz/cdt.toLinkWasm
func toDictLinkWasm(*cdt.Link) *wasm.DictLink

func toGraphWasm(v *Graph) *wasm.Graph {
if v == nil {
return nil
}
return v.wasm
}

0 comments on commit 3789771

Please sign in to comment.