POV-Ray

The Persistence of Vision Raytracer (POV-Ray).

This is the legacy Bug Tracking System for the POV-Ray project. Bugs listed here are being migrated to our github issue tracker. Please refer to that for new reports or updates to existing ones on this system.

Attached to Project: POV-Ray
Opened by Mike H - 2010-06-09
Last edited by Thorsten Fröhlich - 2010-10-26

FS#128 - Mixed-type arrays

Currently, arrays may contain only one object type. Would be nice to eliminate this restriction and allow arrays to contain objects of different types.

Closed by  Thorsten Fröhlich
Tuesday, 26 October 2010, 04:46 GMT
Reason for closing:  Won't implement
Additional comments about closing:  

Requested functionality already available.

Grimbert Jérôme commented on Thursday, 10 June 2010, 11:54 GMT

If an array contains more than one type, how would you know the type of each cell ?
Mixed-type arrays look like a bad programming practice, or a kludge.
Could you provide an example which demonstrate the interest of having a mixed-type array ?

(one of my basic rule from kindergarten: do not mix apples & oranges)

Mike H commented on Sunday, 20 June 2010, 00:28 GMT

Mostly the problem has occurred with multi-dimensional arrays as a way of storing input parameters to be used later, IIRC.

#local apples_array = array[3][3]
{
  // name, color, radius
  {"Macintosh",          x, 5},
  {"Granny Smith",       y, 3},
  {"Golden Delicious", x+y, 4}
}
Grimbert Jérôme commented on Sunday, 24 October 2010, 13:08 GMT

Seems solved from comments in FS#127

Mike H commented on Monday, 25 October 2010, 21:09 GMT

Those comments just recommend multi-dimensional arrays... which just happens to be what I provided in the example above. So, no, I don't think anything was "solved".

Thorsten Fröhlich commented on Tuesday, 26 October 2010, 04:43 GMT
#local apples_array = array[3][3][1]
{
  // name, color, radius
  {{"Macintosh"},          {x}, {5}},
  {{"Granny Smith"},       {y}, {3}},
  {{"Golden Delicious"}, {x+y}, {4}}
}

- solved.

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing