Mercurial > hg > octave-terminal
changeset 7397:26146201e68e
[project @ 2008-01-18 05:12:03 by jwe]
author | jwe |
---|---|
date | Fri, 18 Jan 2008 05:12:03 +0000 |
parents | 0114d8cd1587 |
children | 4f403ccc4e30 |
files | src/ChangeLog src/genprops.awk |
diffstat | 2 files changed, 12 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-18 Juhani Saastamoinen <juhani@cs.joensuu.fi> + + * genprops.awk: Avoid using "default" as a variable name. + 2008-01-17 Michael Goffioul <michael.goffioul@gmail.com> * graphics.h.in (data_property::get_data_limits): Reset min/max values.
--- a/src/genprops.awk +++ b/src/genprops.awk @@ -318,7 +318,7 @@ for (i = 1; i <= idx; i++) { - printf (" %s (\"%s\", mh, %s)", name[i], name[i], default[i]) >> filename; + printf (" %s (\"%s\", mh, %s)", name[i], name[i], defval[i]) >> filename; if (i < idx) printf (",") >> filename; printf ("\n") >> filename; @@ -390,13 +390,13 @@ for (i = 1; i <= idx; i++) { - defval = default[i]; + dval = defval[i]; if (type[i] == "radio_property" || type[i] == "color_property") - defval = gensub (/^.*\{(.*)\}.*$/, "\"\\1\"", "g", defval); - if (! defval) - defval = "octave_value ()"; + dval = gensub (/^.*\{(.*)\}.*$/, "\"\\1\"", "g", dval); + if (! dval) + dval = "octave_value ()"; if (name[i] !~ /__.*/) - printf (" m[\"%s\"] = %s%s;\n", name[i], defval, + printf (" m[\"%s\"] = %s%s;\n", name[i], dval, (type[i] == "handle_property" ? ".as_octave_value ()" : "")) >> filename; } @@ -462,7 +462,7 @@ hidden[idx] = 0; emit_get[idx] = "definition"; emit_set[idx] = "definition"; - default[idx] = ""; + defval[idx] = ""; ## if (type[idx] == "octave_value") ## emit_ov_set[idx] = ""; ## else @@ -533,7 +533,7 @@ field++; for (i = field; i <= NF; i++) - default[idx] = (default[idx] (i > field ? " " : "") $i); + defval[idx] = (defval[idx] (i > field ? " " : "") $i); } }