MCPcopy
hub / github.com/webpack/webpack / consumeReverseSolidus

Function consumeReverseSolidus

lib/css/syntax.js:938–944  ·  view source on GitHub ↗

* `\` — escape starts an ident-like token, otherwise it's a delim. * @param {string} input input * @param {number} pos position just past `\` * @param {MutableToken} out token to populate * @returns {MutableToken | undefined} the resulting token, or undefined at EOF

(input, pos, out)

Source from the content-addressed store, hash-verified

936 * @returns {MutableToken | undefined} the resulting token, or undefined at EOF
937 */
938function consumeReverseSolidus(input, pos, out) {
939 if (_ifTwoCodePointsAreValidEscape(input, pos)) {
940 pos--;
941 return consumeAnIdentLikeToken(input, pos, out);
942 }
943 return fill(out, TT_DELIM, pos - 1, pos);
944}
945
946// `consumeAToken` dispatch: the §4 token rules keyed by the lead code point are
947// === Tokenizer lead-character dispatch (CSS Syntax Level 3 §4 "consume a token") ===

Callers 1

consumeATokenFunction · 0.85

Calls 3

consumeAnIdentLikeTokenFunction · 0.85
fillFunction · 0.85

Tested by

no test coverage detected