Re: RFC: allowing compound assignment operators with designated initializers

2018-10-15 Thread Gabriel Paubert
On Mon, Oct 15, 2018 at 08:13:19PM +0100, Jonathan Wakely wrote: > On Mon, 15 Oct 2018 at 20:08, Gabriel Paubert wrote: > > > > On Mon, Oct 15, 2018 at 08:11:42PM +0200, Florian Weimer wrote: > > > * Jonathan Wakely: > > > > > > > On Sun, 14 Oct 2018 at 20:46, Florian Weimer wrote: > > > >> > > >

Re: RFC: allowing compound assignment operators with designated initializers

2018-10-15 Thread Jonathan Wakely
On Mon, 15 Oct 2018 at 20:08, Gabriel Paubert wrote: > > On Mon, Oct 15, 2018 at 08:11:42PM +0200, Florian Weimer wrote: > > * Jonathan Wakely: > > > > > On Sun, 14 Oct 2018 at 20:46, Florian Weimer wrote: > > >> > > >> * Rasmus Villemoes: > > >> > > >> > This is something I've sometimes found my

Re: RFC: allowing compound assignment operators with designated initializers

2018-10-15 Thread Gabriel Paubert
On Mon, Oct 15, 2018 at 08:11:42PM +0200, Florian Weimer wrote: > * Jonathan Wakely: > > > On Sun, 14 Oct 2018 at 20:46, Florian Weimer wrote: > >> > >> * Rasmus Villemoes: > >> > >> > This is something I've sometimes found myself wishing was supported. The > >> > idea being that one can say > >>

Re: RFC: allowing compound assignment operators with designated initializers

2018-10-15 Thread Florian Weimer
* Jonathan Wakely: > On Sun, 14 Oct 2018 at 20:46, Florian Weimer wrote: >> >> * Rasmus Villemoes: >> >> > This is something I've sometimes found myself wishing was supported. The >> > idea being that one can say >> > >> > unsigned a[] = { [0] = 1, [1] = 3, [0] |= 4, ...} >> > >> > which would en

Re: RFC: allowing compound assignment operators with designated initializers

2018-10-15 Thread Jonathan Wakely
On Sun, 14 Oct 2018 at 20:46, Florian Weimer wrote: > > * Rasmus Villemoes: > > > This is something I've sometimes found myself wishing was supported. The > > idea being that one can say > > > > unsigned a[] = { [0] = 1, [1] = 3, [0] |= 4, ...} > > > > which would end up initializing a[0] to 5. As

Re: RFC: allowing compound assignment operators with designated initializers

2018-10-14 Thread Florian Weimer
* Rasmus Villemoes: > This is something I've sometimes found myself wishing was supported. The > idea being that one can say > > unsigned a[] = { [0] = 1, [1] = 3, [0] |= 4, ...} > > which would end up initializing a[0] to 5. As a somewhat realistic > example, suppose one is trying to build a bitm

RFC: allowing compound assignment operators with designated initializers

2018-10-12 Thread Rasmus Villemoes
This is something I've sometimes found myself wishing was supported. The idea being that one can say unsigned a[] = { [0] = 1, [1] = 3, [0] |= 4, ...} which would end up initializing a[0] to 5. As a somewhat realistic example, suppose one is trying to build a bitmap at compile time, but the bits