mirror of
https://github.com/robertkrimen/otto
synced 2025-10-05 19:19:10 +08:00
[#148] Removed display comment map
This commit is contained in:
parent
6cd63e968f
commit
17dd6bba73
|
@ -3,7 +3,6 @@ package ast
|
|||
import (
|
||||
"fmt"
|
||||
"github.com/robertkrimen/otto/file"
|
||||
"reflect"
|
||||
)
|
||||
|
||||
// CommentPosition determines where the comment is in a given context
|
||||
|
@ -92,15 +91,3 @@ func (cm CommentMap) MoveComments(from, to Node, position CommentPosition) {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Display displays the map
|
||||
func (cm CommentMap) Display() {
|
||||
fmt.Printf("-- Displaying Comment Map --\n")
|
||||
for k, v := range cm {
|
||||
fmt.Printf("Node(%v==%v):\n", k, reflect.TypeOf(k))
|
||||
for i, c := range v {
|
||||
fmt.Printf(" * [%v] \"%v\" (position:%v, begin:%v)\n", i, c.Text, c.Position, c.Begin)
|
||||
}
|
||||
}
|
||||
fmt.Printf("----------------------------\n")
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user