Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c > #163275

Re: on ``vector'' and ``array''

From Meredith Montgomery <mmontgomery@levado.to>
Newsgroups comp.lang.c
Subject Re: on ``vector'' and ``array''
Date 2021-10-31 12:02 -0300
Organization Aioe.org NNTP Server
Message-ID <86cznlb5ki.fsf@levado.to> (permalink)
References (2 earlier) <87fsskugpt.fsf@bsb.me.uk> <61ed0973-6096-415f-bd37-4d3881339cb6n@googlegroups.com> <86bl37kh6m.fsf@levado.to> <17050254-bc0d-4923-8c3d-494678ccca5dn@googlegroups.com> <65a20ab1-1436-453c-b01c-9b37c1a7cf9fn@googlegroups.com>

Show all headers | View raw


Malcolm McLean <malcolm.arthur.mclean@gmail.com> writes:

> On Saturday, 30 October 2021 at 17:33:23 UTC+1, Anand Hariharan wrote:
>> On Friday, October 29, 2021 at 10:04:37 AM UTC-5, Meredith Montgomery wrote: 
>> > Malcolm McLean <malcolm.ar...@gmail.com> writes: 
>> > 
>> > > On Friday, 29 October 2021 at 14:02:36 UTC+1, Ben Bacarisse wrote: 
>> > >> Malcolm McLean <malcolm.ar...@gmail.com> writes: 
>> > >> 
>> > >> > In C++, the term "vector" is misused quite badly to refer to an 
>> > >> > array. That's because early on in the development of the standard 
>> > >> > template library, the identifier "array" was used for an 
>> > >> > inconvenient 
>> > >> > container that is seldom used, creating the need for another name to 
>> > >> > use for the normal array type. 
>> > >> What was array used for in the early STL? std::array is present in 
>> > >> recent versions of C++, but I don't know of the earlier usage. 
>> > >> 
>> > > I've checked and it appears I was wrong. The inconvenient type was 
>> > > "valarray" 
>> > > (an array constrained to hold scalars). "array" was avoided because of 
>> > > the use 
>> > > of the term in the C standard. 
>> > > However Alex Stepanov (the man responsible for the STL) later said he had 
>> > > made a mistake by choosing the identifier "vector". 
>> > Oh, nice. Can you locate the reference? I just searched every 
>> > interview of his from the interviews-section at 
>> > 
>> > http://stepanovpapers.com/ 
>> > 
>> > and did not find any comment to that effect. Thank you!
>> He talks about this some 7' into this ~1 hour long video: 
>> 
>> https://www.youtube.com/watch?v=etZgaSjzqlU 
>> 
> Thanks. I found myself watching the whole thing.

The lecture is indeed really nice.  I had a lot of fun at time 7:07:

  -- Which class would you use?
  -- VECTAR!
  -- Vectar, guys.
  -- You use Vectar.

Back to comp.lang.c | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

on ``vector'' and ``array'' Meredith Montgomery <mmontgomery@levado.to> - 2021-10-29 01:00 -0300
  Re: on ``vector'' and ``array'' Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2021-10-28 21:29 -0700
  Re: on ``vector'' and ``array'' Malcolm McLean <malcolm.arthur.mclean@gmail.com> - 2021-10-29 04:42 -0700
    Re: on ``vector'' and ``array'' Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-10-29 14:02 +0100
      Re: on ``vector'' and ``array'' Malcolm McLean <malcolm.arthur.mclean@gmail.com> - 2021-10-29 06:58 -0700
        Re: on ``vector'' and ``array'' Meredith Montgomery <mmontgomery@levado.to> - 2021-10-29 12:02 -0300
          Re: on ``vector'' and ``array'' Anand Hariharan <mailto.anand.hariharan@gmail.com> - 2021-10-30 09:33 -0700
            Re: on ``vector'' and ``array'' Meredith Montgomery <mmontgomery@levado.to> - 2021-10-30 15:29 -0300
            Re: on ``vector'' and ``array'' Malcolm McLean <malcolm.arthur.mclean@gmail.com> - 2021-10-30 13:25 -0700
              Re: on ``vector'' and ``array'' Meredith Montgomery <mmontgomery@levado.to> - 2021-10-31 12:02 -0300
        Re: on ``vector'' and ``array'' Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-10-29 16:38 +0100
    Re: on ``vector'' and ``array'' Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2021-10-29 11:08 -0700

csiph-web