(s string)
| 2222 | } |
| 2223 | |
| 2224 | func IsValidIdentifier(s string) bool { |
| 2225 | if len(s) == 0 { |
| 2226 | return false |
| 2227 | } |
| 2228 | for i, ch := range s { |
| 2229 | if i == 0 && !IsIdentifierStart(ch) || i != 0 && !IsIdentifierPart(ch) { |
| 2230 | return false |
| 2231 | } |
| 2232 | } |
| 2233 | return true |
| 2234 | } |
| 2235 | |
| 2236 | // Section 6.1.4 |
| 2237 | func isWordCharacter(ch rune) bool { |
no test coverage detected