POV-Ray : Newsgroups : povray.off-topic : The other rant that amused me recently : Re: The other rant that amused me recently Server Time
11 Oct 2024 13:15:32 EDT (-0400)
  Re: The other rant that amused me recently  
From: Warp
Date: 2 Nov 2007 08:06:49
Message: <472b20e8@news.povray.org>
Darren New <dne### [at] sanrrcom> wrote:
> > bits were wasted. I re-implemented the this class so that it would only
> > store as many bits as necessary for each element. This meant that if,
> > for example, the integers stored in this vector had value ranges between
> > 0 and 100000, only 17 bits were allocated for each element, producing a
> > saving of 46% in memory usage.

> That's a keyword in Ada, see. :-) You declare the array "packed" and you 
> get that behavior without writing any extra code.

  The question is not whether the language has direct support for
something specific but if offers you the tools to transparently change
the implementation of such a data container in such way if needed
(including things not directly supported by the compiler).

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.