Drop the comment claims that name callers and List's gaps
This commit is contained in:
+1
-1
@@ -120,7 +120,7 @@ func New(opts ...Option) (*Generator, error) {
|
|||||||
// List returns the sorted dotted paths Fake can render: every category, the dotted
|
// List returns the sorted dotted paths Fake can render: every category, the dotted
|
||||||
// fields within a template, and folder segments. A choice consumes no segment, so a
|
// fields within a template, and folder segments. A choice consumes no segment, so a
|
||||||
// path continues through one only where every variant carries it, which is the
|
// path continues through one only where every variant carries it, which is the
|
||||||
// rule Fake applies too. A selector is left out: Fake also takes `[key]` after a table.
|
// rule Fake applies too.
|
||||||
func (f *Generator) List() []string {
|
func (f *Generator) List() []string {
|
||||||
var out []string
|
var out []string
|
||||||
for _, name := range sortedNames(f.categories) {
|
for _, name := range sortedNames(f.categories) {
|
||||||
|
|||||||
@@ -133,7 +133,7 @@ type builtin struct {
|
|||||||
|
|
||||||
// funcCall splits a "{token}" body shaped name(args) into its parts; ok is false
|
// funcCall splits a "{token}" body shaped name(args) into its parts; ok is false
|
||||||
// for a plain field or alternation body. A '(' without a trailing ')' yields
|
// for a plain field or alternation body. A '(' without a trailing ')' yields
|
||||||
// ok=false; parseFormat reports it as malformed.
|
// ok=false.
|
||||||
func funcCall(body string) (name string, args []string, ok bool) {
|
func funcCall(body string) (name string, args []string, ok bool) {
|
||||||
lp := indexOutside(body, '(')
|
lp := indexOutside(body, '(')
|
||||||
if lp < 0 || !strings.HasSuffix(body, ")") {
|
if lp < 0 || !strings.HasSuffix(body, ")") {
|
||||||
|
|||||||
Reference in New Issue
Block a user