@@ -675,7 +675,7 @@ func (ctx *FmtCtx) FormatNode(n NodeFormatter) {
675
675
// number of characters to be printed.
676
676
func (ctx * FmtCtx ) formatLimitLength (n NodeFormatter , maxLength int ) {
677
677
temp := NewFmtCtx (ctx .flags )
678
- temp .FormatNodeSummary (n )
678
+ temp .formatNodeSummary (n )
679
679
s := temp .CloseAndGetString ()
680
680
if len (s ) > maxLength {
681
681
truncated := s [:maxLength ] + "..."
@@ -731,7 +731,7 @@ func (ctx *FmtCtx) formatSummaryInsert(node *Insert) {
731
731
expr := rows .Select
732
732
if _ , ok := expr .(* SelectClause ); ok {
733
733
ctx .WriteByte (' ' )
734
- ctx .FormatNodeSummary (rows )
734
+ ctx .formatNodeSummary (rows )
735
735
} else if node .Columns != nil {
736
736
ctx .WriteByte ('(' )
737
737
ctx .formatLimitLength (& node .Columns , ColumnLimit )
@@ -754,8 +754,8 @@ func (ctx *FmtCtx) formatSummaryUpdate(node *Update) {
754
754
}
755
755
}
756
756
757
- // FormatNodeSummary recurses into a node for pretty-printing a summarized version.
758
- func (ctx * FmtCtx ) FormatNodeSummary (n NodeFormatter ) {
757
+ // formatNodeSummary recurses into a node for pretty-printing a summarized version.
758
+ func (ctx * FmtCtx ) formatNodeSummary (n NodeFormatter ) {
759
759
switch node := n .(type ) {
760
760
case * Insert :
761
761
ctx .formatSummaryInsert (node )
@@ -775,7 +775,7 @@ func (ctx *FmtCtx) FormatNodeSummary(n NodeFormatter) {
775
775
func AsStringWithFlags (n NodeFormatter , fl FmtFlags , opts ... FmtCtxOption ) string {
776
776
ctx := NewFmtCtx (fl , opts ... )
777
777
if fl .HasFlags (FmtSummary ) {
778
- ctx .FormatNodeSummary (n )
778
+ ctx .formatNodeSummary (n )
779
779
} else {
780
780
ctx .FormatNode (n )
781
781
}
0 commit comments