lua-users home
lua-l archive

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

But as I understand you, you create the C code for this
"" by yourself?

Is it not possible, that you use a first "conf string parameter", e.
g., ...), and the conf parameter would then decide,
whether "wait for end" is used for this command or not?

Or you create two calls, e. g. Redis.call_nowait(...) and
Redis.call_wait(...) (maybe some nicer names of couse...).

You might not like the idea, that the Lua user then has to do this
decision.... . (but to my programming experience, it is very
dangerous, if "automatic decisions" are hidden "inside the
compiler/interpreter" - e. g. when starting C++, I was very fascinated
by operator overloading and used them very often... today I do not
like this any more, because it tends to make code somehow
"unreadable", if you have to expect "unexpected surprises'" - I would
use operator overload functions today only for "very clear things").