lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Hi, all,

Doing some playing with Lua 5.2's goto for branching a script
depending on the string variable returned by an application API
method, in my test case, a method returning the name of the host
operating system. But thus far, I have been unable to persuade goto to
accept a string variable as the target label. I get a missing name
error for the variable label's name. Is this a known limitation or is
there some way to write something like:

s=var
goto s

::var1::
...
goto Exit

::var2::
...
goto Exit
[etc.]

::Exit::

? If so, I would appreciate a pointer on the correct syntax for the
first goto line.

Paul



-- 
[Notice not included in the above original message:  The U.S. National
Security Agency neither confirms nor denies that it intercepted this
message.]