FoldKeyOnly reports whether the folder only consumes the entry key (e.g. 1-variable map comprehensions where iterVar2 is empty and listV1Fold is false).
()
| 2011 | // FoldKeyOnly reports whether the folder only consumes the entry key (e.g. 1-variable map |
| 2012 | // comprehensions where iterVar2 is empty and listV1Fold is false). |
| 2013 | func (f *folder) FoldKeyOnly() bool { |
| 2014 | return f.iterVar2 == "" && !f.listV1Fold |
| 2015 | } |
| 2016 | |
| 2017 | // FoldEntry will either fold comprehension v1 style macros if iterVar2 is unset, or comprehension v2 style |
| 2018 | // macros if both the iterVar and iterVar2 are set to non-empty strings. |
nothing calls this directly
no outgoing calls
no test coverage detected