admin wrote:What's the problem? Looks good to me:
Code: Select all
::msg "This is XY " . '<xyver>' . " = <xyver>";
Sure, so could be
Code: Select all
::msg 'This is XY <xyver> = '."<xyver>";
But doesn't change the fact that
having to do that doesn't really sound good, when it means this wouldn't work anymore:
Code: Select all
::msg 'This is XY <xyver> = '.<xyver>;
I mean, plus all that to gain what? Why couldn't XY deal with this properly:
Code: Select all
$minver="7.60.0009";
assert <xyver>>=$minver, "This script needs at least XY $minver!";
<xyver> is an XY variable, but ">" alone is nothing, neither is "<", why the need for anything?
And really, if anything I would enforce that all strings must be quoted, not to say that now some variables aren't really variables and must be quoted. What I mean is, this doesn't shock me:
Code: Select all
set $path, <curpath>;
$path = <curpath>;
However, this does:
Code: Select all
set $foo, Current path is <curpath>;
$foo = Current path is <curpath>;
Plus, that's really not a good way to do things, cause soon you'll use a "." or a ";" or something that will break everything and you'll wonder why.
Which is why I personally would do this
Code: Select all
// one var to another
set $path, <curpath>;
but this
Code: Select all
// string involved
set $path, "<curpath>\";
And if anything I say enforce the rule that strings must be quoted, but not that some variables are now literal strings and must be quoted -- double-quoted that is, cause single-quotes won't do the trick, because they're not variables but literal strings, only there's string & string... or something
