lua-users home
lua-l archive

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


On Wed, Aug 24, 2011 at 08:20:15PM +0200, Dimiter 'malkia' Stanev wrote:
> Sorry for intruding here, but wouldn't be even more concise (but not not 
> readable at first):
> 
> value first, then keys
> 
> tbl = multi_setval(
> {'good', 'a','b','c'},
> {'bad', 4,5,6},
> {'so_so', 7,'8','9'}
> )
> 
> 
Or, exploiting an existing Lua syntax option to help a little towards
readability:

    tbl = multi_setval(
    {'good'; 'a','b','c'},
    {'bad'; 4,5,6},
    {'so_so'; 7,'8','9'}
    )

Dirk