From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lb0-f175.google.com ([209.85.217.175]) by pp; Tue Mar 10 12:00:45 EDT 2015 Received: by lbjf15 with SMTP id f15so2800500lbj.2 for <9front@9front.org>; Tue, 10 Mar 2015 09:00:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:content-type; bh=vzs9mh2GiUMIbfL8WjED/2J9KWCUdcYRHiMla6CuxhM=; b=dPO7ypKmtK9M5MJhmJQX1wzQzH8HXQYyQbf31MgoqBVgZt6s0WY6+r0GVeMnVMsRMt Km1Kwq3LfvexZaharqLT+HoZNG/EmnMv/Y6VtwuNmyRNPfjrns0/ewHHjVMEXFzUfxTw rGOEHAyMgsL/jBBK4f262HsXAWsHS8KpxQ1M1F7omxu41oVFPikfia9znidgj9S89c6J fDpmvWDIutmx/+H781jv47iH3+M2xi3ROuzGEemNeCBsCjzdpCX+rN/TciEJk7M6Lm5k S0rYB+zDz0hUK2tMMQU9yypy8pMGtanDiXODeb3ZX+4LqRJtuURUT4j/vgxGDac6upkK Ehtg== X-Gm-Message-State: ALoCoQk9s0vlCuKSvVA8KUGYDasJbgnfpIdaAW854lY2sfGRKtTLyRfFXFwzCtMs0EEjty7s/77j MIME-Version: 1.0 X-Received: by 10.112.56.66 with SMTP id y2mr11621503lbp.22.1426003239517; Tue, 10 Mar 2015 09:00:39 -0700 (PDT) Received: by 10.114.172.49 with HTTP; Tue, 10 Mar 2015 09:00:39 -0700 (PDT) In-Reply-To: References: Date: Tue, 10 Mar 2015 17:00:39 +0100 Message-ID: List-ID: <9front.9front.org> X-Glyph: ➈ X-Bullshit: object-oriented package method-oriented STM generator Subject: Re: 2c(2) error From: Giacomo Tesio To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net>, 9front@9front.org Content-Type: multipart/alternative; boundary=001a113499528a55840510f140b1 --001a113499528a55840510f140b1 Content-Type: text/plain; charset=UTF-8 Ehm... obviously I was talking about 2c(1)... Too much coffe, today... :-D 2015-03-10 16:53 GMT+01:00 Giacomo Tesio : > 2c(2) states: > > Array initializers can specify the indices of the array in >> square brackets, as >> int a[] = { [3] 1, [10] 5 }; >> which initializes the third and tenth elements of the >> eleven-element array a. > > > This is somewhat confusing: the third and the tenth element should have > index 2 and 9. Moreover if the tenth element is actually referred by index > 10, why the array should hold eleven elements? > > A simple check shows that actually the array has 11 elements and the one > initialized are the forth and the eleventh. > > > Giacomo > --001a113499528a55840510f140b1 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Ehm... obviously I was talking about 2c(1)...

Too much coffe, today... :-D
<= br>
2015-03-10 16:53 GMT+01:00 Giacomo Tesio <gia= como@tesio.it>:
2c(2) states:

Array initializers can sp= ecify the indices of the array in
=C2=A0 square brackets, as
=C2=A0 = =C2=A0 =C2=A0 int a[] =3D { [3] 1, [10] 5 };
=C2=A0 which initializes th= e third and tenth elements of the
=C2=A0 eleven-element array a.

This is somewhat confusing: the third and the tent= h element should have index 2 and 9. Moreover if the tenth element is actua= lly referred by index 10, why the array should hold eleven elements?
<= /div>

A simple check shows that actually the array= has 11 elements and the one initialized are the forth and the eleventh.


<= /div>
Giacomo

--001a113499528a55840510f140b1--