Sha256: 1d94f402d90ad3135c96acd166a2207bb690142091cd023015f4917de7efb1f2
Contents?: true
Size: 1.41 KB
Versions: 43
Compression:
Stored size: 1.41 KB
Contents
/*jsl:option explicit*/ function missing_break() { var i, o, s; switch (i) { /* okay because of return */ default: return ""; } switch (i) { /* okay because of throw */ default: throw s; } switch (i) { case 1: s += "."; /*missing break*/ case 2: /*warning:missing_break*/ /*okay because of return*/ s += ","; return s; case 3: /*okay because of throw*/ s += ";"; throw s; case 4: /*okay because of break/throw*/ if (s) { break; } else { throw i; } case 5: /*missing break in catch*/ try { i--; break; } catch (err) { s = null; } finally { i++; } case 6: /*warning:missing_break*/ /*ok; finally statement never called*/ try { i--; break; } catch (err) { s = null; break; } finally { i++; } case 7: /*ok; break statement in catch and finally*/ try { i--; } catch (err) { s = null; break; } finally { i++; break; } default: break; } return ""; }
Version data entries
43 entries across 43 versions & 1 rubygems
Version | Path |
---|---|
distil-0.8.1 | vendor/jsl-0.3.0/tests/warnings/missing_break.js |
distil-0.8.0 | vendor/jsl-0.3.0/tests/warnings/missing_break.js |
distil-0.7.0 | vendor/jsl-0.3.0/tests/warnings/missing_break.js |