lua-users home
lua-l archive

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




On Friday, March 27, 2015, Pierre Chapuis <catwell@archlinux.us> wrote:
> 2015-03-26 23:42 GMT+02:00 Andrew Starks <andrew.starks@trms.com>:

> So I'm sure that what you wrote is more helpful than the brutal no-thanks
> of the lazy majority (including me) who gave up on them without trying.

For what it's worth, I was very enthusiastic about those macros and I did
try them. I still have my main Lua built with NOCVTS2N on my laptop and I
do not remember it causing any issue (I had kind of forgotten it was still
on).

NOCVTN2S is more annoying because several libraries depend on this
behavior, like in this example.

--
Pierre Chapuis



I think this is an issue for very generic libraries that really don't know anything about the values that they are concatenating, such as pl. If you want to respect __concat and tostring things that don't have it, then you have to check in ways that aren't that great. 

But that probably isn't a problem outside of generics. Conceptually at least, it might be cleaner if every Lua value defined their __concat event so as to work for the string case. But again, I don't know and have not tested if this would make everything slower and if there would be an every-day gain to such a modification. 

It's easy to try but I'm weighing that experiment against the prospect of just turning the flag off. 

Andrew