At 15:50 16/06/00 +0200, pekr wrote:
>[EMAIL PROTECTED] wrote:
>
> > Yeah, that sounds funny.
> > For me, your example script does throw an error for values other than 1
> or 2.
> > If you are saying that it doesn't for you, then that sounds funny...
> > I tried it on both rebol core 2.2.0.3.1
> > and REBOL/View 0.9.9.3.1 1-Jun-2000
> >
> > The error is:
> > ** Script Error: command0 has no value.
> > ** Where: command0
> >
>
>Of course it does? What do you expect?
From the original question, it sounds like he isn't getting this error
that you and I can get so easily :-)
>1) below script will not work, as rejoin returns "command1" for e.g. as a
>string
>
>->> command: input
>1
>== "1"
>->> type? rejoin ["command" command]
>== string!
>->>
It works for ok for 1 and 2.
>2) if you will put there do to-word rejoin , it will crash for other than
>command1 and command2 values, as there are no words of such name defined
>
>Or am I wrong here?
>
>-pekr-
(Of course you don't mean 'crash', you mean it will give a script error.)
But getting back to the original question (which is not too clearly
worded), it sounds like he isn't getting any error when he enters '0', for
example. If he is *not* getting a script error when he enters '0', then
that's a serious bug.
But I am not sure that's what he means...
[EMAIL PROTECTED]
> >
> > -Anton.
> >
> > At 04:33 16/06/00 -0700, you wrote:
> > >Hi, can anyone tell me what's wrong with
> > >this script and why it does'nt throw an error
> > >for input numbers 1 - 9. thanks alot.. tim
> > >
> > >BEGIN SCRIPT
> > >
> > >REBOL [
> > >]
> > >
> > >Listing: [
> > >
> > >print "Choose Command..."
> > >print "1 - Command 1"
> > >print "2 - Command 2"
> > >]
> > >
> > >
> > >
> > >command1: [print "Doing Command 1"]
> > >command2: [print "Doing Command 2"]
> > >
> > >
> > >
> > >forever [
> > >do listing
> > >command: input
> > >do rejoin ["command" command]
> > >]
-Anton.