MCPcopy Index your code
hub / github.com/rhysd/actionlint / parseStringOrStringSequence

Method parseStringOrStringSequence

parse.go:226–236  ·  view source on GitHub ↗
(sec string, n *yaml.Node, allowEmpty bool, allowElemEmpty bool)

Source from the content-addressed store, hash-verified

224}
225
226func (p *parser) parseStringOrStringSequence(sec string, n *yaml.Node, allowEmpty bool, allowElemEmpty bool) []*String {
227 switch n.Kind {
228 case yaml.ScalarNode:
229 if allowEmpty && n.Tag == "!!null" {
230 return []*String{} // In the case of 'foo:'
231 }
232 return []*String{p.parseString(n, allowElemEmpty)}
233 default:
234 return p.parseStringSequence(sec, n, allowEmpty, allowElemEmpty)
235 }
236}
237
238func (p *parser) parseBool(n *yaml.Node) *Bool {
239 if n.Kind != yaml.ScalarNode || (n.Tag != "!!bool" && n.Tag != "!!str") {

Callers 4

parseWebhookEventMethod · 0.95
parseRunsOnMethod · 0.95

Calls 2

parseStringMethod · 0.95
parseStringSequenceMethod · 0.95

Tested by

no test coverage detected