lua-users home
lua-l archive

Re: Lua as Configuration Conditional Statement inside table definition

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


With the risk that this was buried somewhere in this thread already.
You could do it like:
 Enum1 = ENUMERATION {
     {1, "Forward"},
    {2, "Backword"},
    BIDIERCTIONAL_SUPPORTED and {3, "BiDirectional"},
   {4, "None" }
 }
And then do some post processing in the ENUMERATION function to throw
out all false or nil values from the table. (Be careful with the
definition of "array" and nil in Lua..)
Bye,
Wim

AltStyle によって変換されたページ (->オリジナル) /