(s string)
| 436 | } |
| 437 | |
| 438 | func parseQuotedName(s string) (name string, n int, err error) { |
| 439 | for n = 1; n < len(s); n++ { |
| 440 | if s[n] == '"' && s[n-1] != '\\' { |
| 441 | n++ |
| 442 | break |
| 443 | } |
| 444 | } |
| 445 | if n == 2 { |
| 446 | return "", 0, fmt.Errorf("missing name") |
| 447 | } |
| 448 | if name, err = strconv.Unquote(s[:n]); err != nil { |
| 449 | return "", 0, err |
| 450 | } |
| 451 | return name, n, err |
| 452 | } |
| 453 | |
| 454 | func parseUnquotedName(s string, term byte) (name string, n int, err error) { |
| 455 | for n = 0; n < len(s); n++ { |
no test coverage detected