File: comment.go

package info (click to toggle)
golang-github-yosssi-ace 0.0.5-3.1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 484 kB
  • sloc: makefile: 21; sh: 1
file content (25 lines) | stat: -rw-r--r-- 503 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
package ace

import "io"

// comment represents a comment.
type comment struct {
	elementBase
}

// Do nothing.
func (e *comment) WriteTo(w io.Writer) (int64, error) {
	return 0, nil
}

// ContainPlainText returns true.
func (e *comment) ContainPlainText() bool {
	return true
}

// newComment creates and returns a comment.
func newComment(ln *line, rslt *result, src *source, parent element, opts *Options) *comment {
	return &comment{
		elementBase: newElementBase(ln, rslt, src, parent, opts),
	}
}