[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Say No to global-by-default (summary of the discussion)
- From: Dirk Laurie <dirk.laurie@...>
- Date: Tue, 31 Jul 2018 11:00:20 +0200
2018-07-31 8:55 GMT+02:00 Sergey Zakharchenko <doublef.mobile@gmail.com>:
> Dirk,
>
>> The only [1] place in Lua where syntax sugar saves you one statement is
>
> How about
>
> a():b()
>
> vs
>
> local dummy=a();dummy.b(dummy) ?
Thanks. I forgot about that one. But it is not quite equivalent;
(object_valued_expression):method(...) saves you a named local but
then you don't have that named local.
- References:
- Say No to global-by-default (summary of the discussion), Egor Skriptunoff
- Re: Say No to global-by-default (summary of the discussion), Dirk Laurie
- Re: Say No to global-by-default (summary of the discussion), Egor Skriptunoff
- Re: Say No to global-by-default (summary of the discussion), Luiz Henrique de Figueiredo
- Re: Say No to global-by-default (summary of the discussion), Dirk Laurie
- Re: Say No to global-by-default (summary of the discussion), Egor Skriptunoff
- Re: Say No to global-by-default (summary of the discussion), Dirk Laurie
- Re: Say No to global-by-default (summary of the discussion), Egor Skriptunoff
- Re: Say No to global-by-default (summary of the discussion), Sean Conner
- Re: Say No to global-by-default (summary of the discussion), dyngeccetor8
- Re: Say No to global-by-default (summary of the discussion), Dirk Laurie
- Re: Say No to global-by-default (summary of the discussion), Sergey Zakharchenko