MCPcopy Index your code
hub / github.com/php/frankenphp / findMatchingComment

Function findMatchingComment

internal/extgen/classparser.go:276–286  ·  view source on GitHub ↗

findMatchingComment returns the raw comment text whose line matches re.

(group *ast.CommentGroup, re *regexp.Regexp)

Source from the content-addressed store, hash-verified

274
275// findMatchingComment returns the raw comment text whose line matches re.
276func findMatchingComment(group *ast.CommentGroup, re *regexp.Regexp) string {
277 if group == nil {
278 return ""
279 }
280 for _, comment := range group.List {
281 if re.MatchString(comment.Text) {
282 return comment.Text
283 }
284 }
285 return ""
286}
287
288func (cp *classParser) parseMethodSignature(className, signature string) (*phpClassMethod, error) {
289 name, params, returnType, nullable, err := parseSignatureParams(signature)

Callers 1

parseMethodsMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected