From b6be82b8edefa452e72ed53391971e53d9dccf83 Mon Sep 17 00:00:00 2001 From: Peter Wu Date: Fri, 25 Jul 2014 23:28:21 +0200 Subject: jsrrdgraph: Fixed jshint warnings/errors Many fall in the category missing semicolon, but there are legitimate bugs (like throwing an error with an undefined variable, using isInfinite instead of !isFinite or fabs instead of Math.abs). At some places, I moved the variable declarations to avoid duplicate definition warnings. Redundant breaks have been removed (after return / throw). Global variables were implicitly defined in RrdDataFile (which caught my attention) and Base64, these have been made local. Also fixed some whitespace errors. Yay, the consistency. Not all (style) issues are fixed. --- js/RrdCmdLine.js | 26 ++++++-------- js/RrdDataFile.js | 21 +++++------ js/RrdGfxCanvas.js | 13 +++---- js/RrdGfxPdf.js | 8 ++--- js/RrdGfxSvg.js | 2 +- js/RrdGraph.js | 65 ++++++++++++++++----------------- js/RrdJson.js | 103 ++++++++++++++++++++++++++++------------------------- js/RrdRpn.js | 4 +-- js/RrdTime.js | 42 ++++++++++++---------- js/base64.js | 5 +-- js/rrdFile.js | 2 +- js/sprintf.js | 35 ++++++++---------- js/strftime.js | 77 ++++++++++++--------------------------- 13 files changed, 185 insertions(+), 218 deletions(-) diff --git a/js/RrdCmdLine.js b/js/RrdCmdLine.js index ceec693..a2be92e 100644 --- a/js/RrdCmdLine.js +++ b/js/RrdCmdLine.js @@ -184,6 +184,8 @@ RrdCmdLine.prototype = { }, set_option: function(option, value) { + var args = value.split(':'); + var index = value.indexOf(':'); switch(option) { case 'base': case 'b': @@ -193,12 +195,12 @@ RrdCmdLine.prototype = { break; case 'color': case 'c': - var index = value.indexOf('#'); + index = value.indexOf('#'); if (index === -1) throw "invalid color def format"; var name = value.substr(0,index); if (!this.graph.GRC[name]) - throw "invalid color name '"+name+"'" + throw "invalid color name '" + name + "'"; this.graph.GRC[name] = value.substr(index); // FIXME check color break; case 'end': @@ -212,7 +214,7 @@ RrdCmdLine.prototype = { break; case 'graph-render-mode': case 'G': - // im->graph_antialias + // im->graph_antialias break; case 'height': case 'h': @@ -225,7 +227,7 @@ RrdCmdLine.prototype = { break; case 'lower-limit': case 'l': - this.graph.setminval = parseFloat(value) + this.graph.setminval = parseFloat(value); break; case 'zoom': case 'm': @@ -235,11 +237,10 @@ RrdCmdLine.prototype = { break; case 'font': case 'n': - var args = value.split(':'); if (args.length !== 3) throw "invalid text property format"; if (!this.graph.TEXT[args[0]]) - throw "invalid fonttag '"+args[0]+"'" + throw "invalid font tag '" + args[0] + "'"; if (args[1] > 0) this.graph.TEXT[args[0]].size = args[1]; if (args[2]) @@ -292,7 +293,6 @@ RrdCmdLine.prototype = { if (value === 'none') { this.graph.draw_x_grid = false; } else { - var args = value.split(':'); if (args.length !== 8) throw "invalid x-grid format"; this.graph.xlab_user.gridtm = this.graph.tmt_conv(args[0]); @@ -318,7 +318,6 @@ RrdCmdLine.prototype = { if (value === 'none') { this.graph.draw_y_grid = false; } else { - var index = value.indexOf(':'); if (index === -1) throw "invalid y-grid format"; this.graph.ygridstep = parseFloat(value.substr(0,index)); @@ -338,7 +337,6 @@ RrdCmdLine.prototype = { throw "invalid argument for --units: "+value; break; case 'right-axis': - var index = value.indexOf(':'); if (index === -1) throw "invalid right-axis format expected scale:shift"; this.graph.second_axis_scale = parseFloat(value.substr(0,index)); @@ -378,7 +376,6 @@ RrdCmdLine.prototype = { this.graph.draw_3d_border = parseInt(value, 10); break; case 'grid-dash': - var index = value.indexOf(':'); if (index === -1) throw "expected grid-dash format float:float"; this.graph.grid_dash_on = parseFloat(value.substr(0,index)); @@ -399,20 +396,17 @@ RrdCmdLine.prototype = { var rrdfile = vnames[1]; var name = args[n++]; var cf = args[n++]; - var step = undefined; - var reduce = undefined; - var start = undefined; - var end = undefined; + var step, reduce, start, end; if (args.length > n) { for (var j = n, xlen = args.length ; j < xlen ; j++) { var opts = args[j].split("="); if (opts[0] === "step") step = opts[1]; - if (opts[0] === "reduce") reduce = opts[1] + if (opts[0] === "reduce") reduce = opts[1]; if (opts[0] === "start") start = opts[1]; if (opts[0] === "end") end = opts[1]; } } - this.graph.gdes_add_def(vname, rrdfile, name, cf, step, start, end, reduce) + this.graph.gdes_add_def(vname, rrdfile, name, cf, step, start, end, reduce); }, // CDEF:vname=RPN expression parse_cdef: function (line) diff --git a/js/RrdDataFile.js b/js/RrdDataFile.js index 4ebb220..2c0e846 100644 --- a/js/RrdDataFile.js +++ b/js/RrdDataFile.js @@ -42,21 +42,23 @@ RrdDataFile.prototype = { var cal_start, cal_end; var best_full_rra = 0, best_part_rra = 0, chosen_rra = 0; var best_full_step_diff = 0, best_part_step_diff = 0, tmp_step_diff = 0, tmp_match = 0, best_match = 0; - var full_match, rra_base; + var full_match; var first_full = 1; var first_part = 1; var data_ptr; var rows; + var rra; + var i, ii; var cf_idx = gdp.cf; var ds_cnt = rrd.getNrDSs(); var rra_cnt = rrd.getNrRRAs(); - for (var i = 0; i < ds_cnt; i++) + for (i = 0; i < ds_cnt; i++) gdp.ds_namv[i] = rrd.rrd_header.getDSbyIdx(i).getName(); - for (var i = 0; i < rra_cnt; i++) { - var rra = rrd.getRRAInfo(i); + for (i = 0; i < rra_cnt; i++) { + rra = rrd.getRRAInfo(i); if (RrdGraphDesc.cf_conv(rra.getCFName()) === cf_idx) { cal_end = (rrd.getLastUpdate() - (rrd.getLastUpdate() % (rra.getPdpPerRow() * rra.pdp_step))); cal_start = (cal_end - (rra.getPdpPerRow() * rra.row_cnt * rra.pdp_step)); @@ -87,7 +89,7 @@ RrdDataFile.prototype = { else throw "the RRD does not contain an RRA matching the chosen CF"; var rra_info = rrd.getRRAInfo(chosen_rra); - var rra = rrd.getRRA(chosen_rra); + rra = rrd.getRRA(chosen_rra); ft_step = rrd.rrd_header.pdp_step * rra_info.getPdpPerRow(); gdp.start -= (gdp.start % ft_step); @@ -107,13 +109,13 @@ RrdDataFile.prototype = { for (i = start_offset; i < rra.row_cnt - end_offset; i++) { if (i < 0) { - for (var ii = 0; ii < ds_cnt; ii++) + for (ii = 0; ii < ds_cnt; ii++) gdp.data[data_ptr++] = Number.NaN; } else if (i >= rra.row_cnt) { - for (var ii = 0; ii < ds_cnt; ii++) + for (ii = 0; ii < ds_cnt; ii++) gdp.data[data_ptr++] = Number.NaN; } else { - for (var ii = 0; ii < ds_cnt; ii++) + for(ii = 0; ii < ds_cnt; ii++) gdp.data[data_ptr++] = rra.getEl(i, ii); } } @@ -153,8 +155,7 @@ RrdDataFile.prototype = { }, fetch_async: function(gdp, ft_step, callback, callback_arg) { - var rrd; - if (gdp.rrd == null) return -1; + if (gdp.rrd === null) return -1; if (gdp.rrd in this.rrdfiles) { callback(callback_arg, this.build(gdp, ft_step, this.rrdfiles[gdp.rrd])); diff --git a/js/RrdGfxCanvas.js b/js/RrdGfxCanvas.js index 070b806..0d1784e 100644 --- a/js/RrdGfxCanvas.js +++ b/js/RrdGfxCanvas.js @@ -57,7 +57,7 @@ RrdGfxCanvas.prototype.line = function (X0, Y0, X1, Y1, width, color) } this.ctx.save(); this.ctx.lineWidth = width; - this.ctx.strokeStyle = color + this.ctx.strokeStyle = color; this.ctx.beginPath(); this.ctx.moveTo(X0, Y0); this.ctx.lineTo(X1, Y1); @@ -67,6 +67,7 @@ RrdGfxCanvas.prototype.line = function (X0, Y0, X1, Y1, width, color) RrdGfxCanvas.prototype.dashed_line = function (X0, Y0, X1, Y1, width, color, dash_on, dash_off) { + var swap, n; X0 = Math.round(X0); Y0 = Math.round(Y0); X1 = Math.round(X1); @@ -81,12 +82,12 @@ RrdGfxCanvas.prototype.dashed_line = function (X0, Y0, X1, Y1, width, color, das Y0 += 0.5; Y1 += 0.5; if (X0 > X1) { - var swap = X0; + swap = X0; X0 = X1; X1 = swap; } this.ctx.moveTo(X0, Y0); - var n=0; + n = 0; while(X0<=X1) { if (n%2 === 1) { X0 += dash_on; @@ -101,12 +102,12 @@ RrdGfxCanvas.prototype.dashed_line = function (X0, Y0, X1, Y1, width, color, das X0 += 0.5; X1 += 0.5; if (Y0 > Y1) { - var swap = Y0; + swap = Y0; Y0 = Y1; Y1 = swap; } this.ctx.moveTo(X0, Y0); - var n=0; + n = 0; while(Y0<=Y1) { if (n%2 === 1) { Y0 += dash_on; @@ -201,7 +202,7 @@ RrdGfxCanvas.prototype.lineTo = function (x,y) { x = Math.round(x)+0.5; y = Math.round(y)+0.5; - this.ctx.lineTo(x, y) + this.ctx.lineTo(x, y); }; RrdGfxCanvas.prototype.text = function (x, y, color, font, tabwidth, angle, h_align, v_align, text) diff --git a/js/RrdGfxPdf.js b/js/RrdGfxPdf.js index 9203020..230d441 100644 --- a/js/RrdGfxPdf.js +++ b/js/RrdGfxPdf.js @@ -267,7 +267,7 @@ RrdGfxPdf.prototype.moveTo = function (x,y) RrdGfxPdf.prototype.lineTo = function (x,y) { - this._lineTo(x, y) + this._lineTo(x, y); }; RrdGfxPdf.prototype.text = function (x, y, color, font, tabwidth, angle, h_align, v_align, text) @@ -319,7 +319,7 @@ RrdGfxPdf.prototype.text = function (x, y, color, font, tabwidth, angle, h_align } x = x*this.k; - y = (this.h-y)*this.k + y = (this.h-y)*this.k; var tm = []; tm[0] = Math.cos(angle*Math.PI/180.0); @@ -834,7 +834,7 @@ RrdGfxPdf.prototype._putstream = function(s) this._out('stream'); this._out(s); this._out('endstream'); -}, +}; RrdGfxPdf.prototype._out = function(s) { @@ -964,7 +964,7 @@ RrdGfxPdf.prototype._putcatalog = function() this._out('/OpenAction [3 0 R /FitH null]'); else if(this.ZoomMode=='real') this._out('/OpenAction [3 0 R /XYZ null null 1]'); - else if(!(typeof this.ZoomMode === 'string')) + else if(typeof this.ZoomMode !== 'string') this._out('/OpenAction [3 0 R /XYZ null null '+sprintf('%.2F',this.ZoomMode/100)+']'); if(this.LayoutMode=='single') diff --git a/js/RrdGfxSvg.js b/js/RrdGfxSvg.js index 2bdc1b9..ffc0071 100644 --- a/js/RrdGfxSvg.js +++ b/js/RrdGfxSvg.js @@ -25,7 +25,7 @@ * @constructor */ var RrdGfxSvg = function(svgId) { - this.svg = document.getElementById(svgId) + this.svg = document.getElementById(svgId); this.svgns = "http://www.w3.org/2000/svg"; this.xmlns = "http://www.w3.org/XML/1998/namespace"; this.path = null; diff --git a/js/RrdGraph.js b/js/RrdGraph.js index 55a131d..7171a9c 100644 --- a/js/RrdGraph.js +++ b/js/RrdGraph.js @@ -88,7 +88,7 @@ var RrdGraphDesc = function (graph) /** ** **/ var args = []; // FIXME other way ¿? - var type = arguments[1] + var type = arguments[1]; args[0] = arguments[0]; for(var i = 2; i < arguments.length; i++) args[i-1] = arguments[i]; @@ -707,7 +707,7 @@ var RrdGraph = function (gfx, data) { this.gfx = gfx; /* graphics object */ this.data = data; /* fetch data object */ - this.data_need_fetch = [] /* List of data that need to be fetched */ + this.data_need_fetch = []; /* List of data that need to be fetched */ this.minval = Number.NaN; /* extreme values in the data */ this.maxval = Number.NaN; @@ -1197,13 +1197,13 @@ RrdGraph.prototype.print_calc = function() case RrdGraphDesc.GF_HRULE: if (isNaN(this.gdes[i].yrule)) { /* we must set this here or the legend printer can not decide to print the legend */ this.gdes[i].yrule = this.gdes[vidx].vf.val; - }; + } graphelement = 1; break; case RrdGraphDesc.GF_VRULE: if (this.gdes[i].xrule === 0) { /* again ... the legend printer needs it */ this.gdes[i].xrule = this.gdes[vidx].vf.when; - }; + } graphelement = 1; break; case RrdGraphDesc.GF_COMMENT: @@ -1216,7 +1216,6 @@ RrdGraph.prototype.print_calc = function() break; case RrdGraphDesc.GF_STACK: throw new RrdGraphError("STACK should already be turned into LINE or AREA here"); - break; } } return graphelement; @@ -1287,7 +1286,7 @@ RrdGraph.prototype.reduce_data = function(gdes, cur_step) newval = gdes.data[srcptr + i*gdes.ds_cnt + col]; break; } - } + } } if (validval === 0) { @@ -1316,8 +1315,8 @@ RrdGraph.prototype.reduce_data = function(gdes, cur_step) row_cnt -= reduce_factor; } if (end_offset) { - for (col = 0; col < gdes.ds_cnt; col++) - gdes.data[dstptr++] = Number.NaN; + for (col = 0; col < gdes.ds_cnt; col++) + gdes.data[dstptr++] = Number.NaN; } }; @@ -1396,7 +1395,7 @@ RrdGraph.prototype.data_fetch_async = function () } } this.data_need_fetch.push(0); - } + } for (var i = 0, gdes_c = this.gdes.length; i < gdes_c; i++) { if (this.data_need_fetch[i] == 0) { @@ -1619,7 +1618,6 @@ RrdGraph.prototype.data_proc = function() break; case RrdGraphDesc.GF_STACK: throw new RrdGraphError("STACK should already be turned into LINE or AREA here"); - break; default: break; } @@ -1699,7 +1697,7 @@ RrdGraph.prototype.leg_place = function (calc_width) } if (this.gdes[i].legend != null) { - this.gdes[i].legend = this.gdes[i].legend.replace(/\\t/gi, "\t") /* turn \\t into tab */ + this.gdes[i].legend = this.gdes[i].legend.replace(/\\t/gi, "\t"); /* turn \\t into tab */ leg_cc = this.gdes[i].legend.length; } else { leg_cc = 0; @@ -1863,7 +1861,7 @@ RrdGraph.prototype.horizontal_log_grid = function () [ 1.0, 2.0, 4.0, 6.0, 8.0, 10., 0.0, 0.0, 0.0, 0.0 ], [ 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, 10. ], [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] /* last line */ - ]; + ]; var i, j, val_exp, min_exp; var nex; /* number of decades in data */ var logscale; /* scale in logarithmic space */ @@ -1885,7 +1883,7 @@ RrdGraph.prototype.horizontal_log_grid = function () /* major spacing for less dynamic data */ do { mid++; - for (i = 0; yloglab[mid][i + 1] < 10.0; i++) {}; + for (i = 0; yloglab[mid][i + 1] < 10.0; i++) ; mspac = logscale * Math.log(10.0 / yloglab[mid][i])/Math.LN10; } while (mspac > 1.56 * this.TEXT.LEGEND.size && yloglab[mid][0] > 0); // FIXME 2->1.56 ?? if (mid) mid--; @@ -1966,7 +1964,7 @@ RrdGraph.prototype.horizontal_log_grid = function () if (mid < 4 && exfrac === 1) { /* minor grid */ if (flab === 0) { /* find first and last minor line behind current major line * i is the first line and j tha last */ min_exp = val_exp - 1; - for (i = 1; yloglab[mid][i] < 10.0; i++) {}; + for (i = 1; yloglab[mid][i] < 10.0; i++) ; i = yloglab[mid][i - 1] + 1; j = 10; } else { @@ -2002,7 +2000,7 @@ RrdGraph.prototype.horizontal_log_grid = function () if (mid < 4 && exfrac === 1) { /* draw minor lines after highest major line */ if (flab === 0) { /* find first and last minor line below current major line * i is the first line and j tha last */ min_exp = val_exp - 1; - for (i = 1; yloglab[mid][i] < 10.0; i++) {}; + for (i = 1; yloglab[mid][i] < 10.0; i++) ; i = yloglab[mid][i - 1] + 1; j = 10; } else { @@ -2386,20 +2384,20 @@ RrdGraph.prototype.grid_paint = function() this.GRC.FONT, this.TEXT.TITLE, this.tabwidth, 0.0, RrdGraph.GFX_H_CENTER, RrdGraph.GFX_V_TOP, this.title); /* rrdtool 'logo' */ if (!this.no_rrdtool_tag){ - var color = this.parse_color(this.GRC.FONT); - color[3] = 0.3; - var water_color = this.color2rgba(color); - var xpos = this.legendposition === RrdGraph.LEGEND_POS_EAST ? this.xOriginLegendY : this.ximg - 4; - this.gfx.text(xpos, 5, water_color, this.TEXT.WATERMARK, this.tabwidth, - -90, RrdGraph.GFX_H_LEFT, RrdGraph.GFX_V_TOP, "RRDTOOL / TOBI OETIKER"); + var color = this.parse_color(this.GRC.FONT); + color[3] = 0.3; + var water_color = this.color2rgba(color); + var xpos = this.legendposition === RrdGraph.LEGEND_POS_EAST ? this.xOriginLegendY : this.ximg - 4; + this.gfx.text(xpos, 5, water_color, this.TEXT.WATERMARK, this.tabwidth, + -90, RrdGraph.GFX_H_LEFT, RrdGraph.GFX_V_TOP, "RRDTOOL / TOBI OETIKER"); } /* graph watermark */ if (this.watermark) { - var color = this.parse_color(this.GRC.FONT) - color[3] = 0.3; - var water_color = this.color2rgba(color); - this.gfx.text(this.ximg / 2, this.yimg - 6, water_color, this.TEXT.WATERMARK , this.tabwidth, 0, - RrdGraph.GFX_H_CENTER, RrdGraph.GFX_V_BOTTOM, this.watermark); + var color = this.parse_color(this.GRC.FONT); + color[3] = 0.3; + var water_color = this.color2rgba(color); + this.gfx.text(this.ximg / 2, this.yimg - 6, water_color, this.TEXT.WATERMARK , this.tabwidth, 0, + RrdGraph.GFX_H_CENTER, RrdGraph.GFX_V_BOTTOM, this.watermark); } /* graph labels */ if (!(this.no_legend) && !(this.only_graph)) { @@ -2664,11 +2662,11 @@ RrdGraph.prototype.graph_paint_init = function() // this.gdes[i].end_orig = this.end; } -} +}; RrdGraph.prototype.graph_paint_draw = function() { - var areazero = 0.0 + var areazero = 0.0; var lastgdes = null; if (this.data_calc() === -1) @@ -2773,7 +2771,7 @@ RrdGraph.prototype.graph_paint_draw = function() this.gfx.moveTo(x, y); x = ii + this.xorigin; y = last_y; - this.gfx.lineTo(x, y) + this.gfx.lineTo(x, y); } else { var x = ii - 1 + this.xorigin; var y = this.ytr(this.gdes[i].p_data[ii - 1]); @@ -2886,7 +2884,6 @@ RrdGraph.prototype.graph_paint_draw = function() break; case RrdGraphDesc.GF_STACK: throw new RrdGraphError("STACK should already be turned into LINE or AREA here"); - break; } } //cairo_reset_clip(this.cr); @@ -2920,16 +2917,16 @@ RrdGraph.prototype.graph_paint_draw = function() RrdGraph.prototype.graph_paint = function () { - this.graph_paint_init() + this.graph_paint_init(); if (this.data_fetch() === -1) return -1; - return this.graph_paint_draw() + return this.graph_paint_draw(); }; RrdGraph.prototype.graph_paint_async = function () { - this.graph_paint_init() - this.data_fetch_async() + this.graph_paint_init(); + this.data_fetch_async(); }; RrdGraph.prototype.find_var = function(key) diff --git a/js/RrdJson.js b/js/RrdJson.js index fcbf76b..4ddcbc2 100644 --- a/js/RrdJson.js +++ b/js/RrdJson.js @@ -26,11 +26,11 @@ */ var RrdJson = function() { if (arguments.length == 1) { - this.init1.apply(this, arguments); + this.init1.apply(this, arguments); } else if (arguments.length == 2) { - this.init2.apply(this, arguments); + this.init2.apply(this, arguments); } else if (arguments.length == 3) { - this.init3.apply(this, arguments); + this.init3.apply(this, arguments); } }; @@ -40,12 +40,12 @@ RrdJson.prototype = { init1: function (rrdgraph) { - this.graph = rrdgraph + this.graph = rrdgraph; }, init2: function (rrdgraph, jsonstr) { this.json = JSON.parse(jsonstr); - this.graph = rrdgraph + this.graph = rrdgraph; }, init3: function (gfx, fetch, jsonstr) { @@ -69,7 +69,7 @@ RrdJson.prototype = { if (color in this.graph.GRC) { this.graph.GRC[color] = this.json.color[color]; } else { - throw "invalid color name '"+name+"'"; + throw "invalid color '" + color + "'"; } } break; @@ -191,16 +191,21 @@ RrdJson.prototype = { this.graph.second_axis_format = this.json.right_axis_format; break; case 'legend_position': - if (this.json.legend_position === "north") { - this.graph.legendposition = this.graph.LEGEND_POS.NORTH; - } else if (this.json.legend_position === "west") { - this.graph.legendposition = this.graph.LEGEND_POS.WEST; - } else if (this.json.legend_position === "south") { - this.graph.legendposition = this.graph.LEGEND_POS.SOUTH; - } else if (this.json.legend_position === "east") { - this.graph.legendposition = this.graph.LEGEND_POS.EAST; - } else { - throw "unknown legend-position '"+value+"'"; + switch (this.json.legend_position) { + case "north": + this.graph.legendposition = this.graph.LEGEND_POS.NORTH; + break; + case "west": + this.graph.legendposition = this.graph.LEGEND_POS.WEST; + break; + case "south": + this.graph.legendposition = this.graph.LEGEND_POS.SOUTH; + break; + case "east": + this.graph.legendposition = this.graph.LEGEND_POS.EAST; + break; + default: + throw "unknown legend-position '" + this.json.legend_position + "'"; } break; case 'legend_direction': @@ -209,7 +214,7 @@ RrdJson.prototype = { } else if (this.json.legend_direction === "bottomup") { this.graph.legenddirection = this.graph.LEGEND_DIR.BOTTOM_UP; } else { - throw "unknown legend-position '"+value+"'"; + throw "unknown legend-direction'" + this.json.legend_direction + "'"; } break; case 'border': @@ -272,21 +277,21 @@ RrdJson.prototype = { switch (gdes[i].align) { case 'left': this.graph.gdes_add_textalign(RrdGraphDesc.TXA_LEFT); - break + break; case 'right': this.graph.gdes_add_textalign(RrdGraphDesc.TXA_RIGHT); - break + break; case 'justified': this.graph.gdes_add_textalign(RrdGraphDesc.TXA_JUSTIFIED); - break + break; case 'center': this.graph.gdes_add_textalign(RrdGraphDesc.TXA_CENTER); - break + break; } break; // DEF:=::[:step=][:start=