MCPcopy
hub / github.com/PaulTaykalo/objc-dependency-visualizer / warning

Function warning

Scripts/ace/worker-javascript.js:2747–2792  ·  view source on GitHub ↗
(code, t, a, b, c, d)

Source from the content-addressed store, hash-verified

2745 }
2746
2747 function warning(code, t, a, b, c, d) {
2748 var ch, l, w, msg;
2749
2750 if (/^W\d{3}$/.test(code)) {
2751 if (state.ignored[code])
2752 return;
2753
2754 msg = messages.warnings[code];
2755 } else if (/E\d{3}/.test(code)) {
2756 msg = messages.errors[code];
2757 } else if (/I\d{3}/.test(code)) {
2758 msg = messages.info[code];
2759 }
2760
2761 t = t || state.tokens.next;
2762 if (t.id === "(end)") { // `~
2763 t = state.tokens.curr;
2764 }
2765
2766 l = t.line || 0;
2767 ch = t.from || 0;
2768
2769 w = {
2770 id: "(error)",
2771 raw: msg.desc,
2772 code: msg.code,
2773 evidence: state.lines[l - 1] || "",
2774 line: l,
2775 character: ch,
2776 scope: JSHINT.scope,
2777 a: a,
2778 b: b,
2779 c: c,
2780 d: d
2781 };
2782
2783 w.reason = supplant(msg.desc, w);
2784 JSHINT.errors.push(w);
2785
2786 removeIgnoredMessages();
2787
2788 if (JSHINT.errors.length >= state.option.maxerr)
2789 quit("E043", l, ch);
2790
2791 return w;
2792 }
2793
2794 function warningAt(m, l, ch, a, b, c, d) {
2795 return warning(m, {

Callers 15

warningAtFunction · 0.85
errorFunction · 0.85
addlabelFunction · 0.85
advanceFunction · 0.85
expressionFunction · 0.85
nobreaknonadjacentFunction · 0.85
nolinebreakFunction · 0.85
nobreakcommaFunction · 0.85
prefixFunction · 0.85
infixFunction · 0.85
relationFunction · 0.85
assignopFunction · 0.85

Calls 3

supplantFunction · 0.85
removeIgnoredMessagesFunction · 0.85
quitFunction · 0.85

Tested by

no test coverage detected