extract comments package

This commit is contained in:
z7zmey
2018-01-09 00:30:28 +02:00
parent b7b859edaa
commit 99856ae32f
165 changed files with 2447 additions and 3015 deletions

View File

@@ -1,5 +1,13 @@
package comment
import "github.com/z7zmey/php-parser/node"
type Comment interface {
String() string
}
type Comments map[node.Node][]Comment
func (c Comments) AddComments(node node.Node, comments []Comment) {
c[node] = append(c[node], comments...)
}