ietf-mta-filters
[Top] [All Lists]

Re: variables: open issue a) date variables

2003-05-03 14:01:11
On Saturday 03 May 2003 02:06, Kjetil Torgrim Homme wrote:
<snip>
they are not really magic.  you can do
  SETDATE;
  SET "year" "${year} AD";
<snip>
    set "#imapflags" "${#imapflags} \\Seen"
<snip>
that's just _too_ magic :-)
<snip>
Alternatively, assignment to system variables could be
disallowed.  I think would be the the best way to handle it,
since it also prevents users from defining variables in the system
namespace (which wouldn't be too problematic, given that system
variables spring into life only if their extension is require'd).

yes.

So you say that
  set "year" "${year} AD";
is possible, but that
  set "imapflags" "${imapflags} \\Seen";
is too magic and writing to system variables should be disallowed?

I agree with the latter, but not with the former. I don't see the 
usefulness of
  set "year" "${year} AD";
since
1. It can lead to hard-to-find bugs if, in a large script, you alter the
   value of "year" and way down the script test against ${year}.
and more importantly,
2. What does the above solve that can't be solved by
     set "myyear" "${year} AD";

Marc

-- 
Military justice is to justice what military music is to music.
                                                  -- Groucho Marx

Attachment: pgpsDXJUUnvSy.pgp
Description: signature