Newsgroups: comp.lang.smalltalk
Path: cantaloupe.srv.cs.cmu.edu!das-news2.harvard.edu!news4.ner.bbnplanet.net!news3.near.net!paperboy.wellfleet.com!news-feed-1.peachnet.edu!usenet.eel.ufl.edu!news.mathworks.com!newshost.marcam.com!usc!math.ohio-state.edu!cs.utexas.edu!news.sprintlink.net!demon!uknet!dcs.gla.ac.uk!aran
From: aran@dcs.gla.ac.uk (Aran Lunzer)
Subject: VW2.0 TableAdaptor bug
Message-ID: <DBMt3J.H14@dcs.gla.ac.uk>
Organization: Computing Science Dept., Glasgow University, Glasgow, Scotland
Date: Thu, 13 Jul 1995 01:50:07 GMT
Lines: 27

The TableAdaptor class has been updated in VisualWorks 2.0, but
this has brought a bug with it.  I couldn't find a fix in the
patches, so maybe it hadn't been spotted yet.

The problem is that you can't ask for the "rows" of a table that
you have transposed (one of the new, improved facilities of the class).
Without going into details, one solution is to update the following 
private method:

 valueOfElementsAtIndex: anInteger
  | cArray |
  cArray := Array new: baseCollection size.
  1 to: cArray size do: 
    [ :i | 
    cArray at: i put: (adaptors access: (baseCollection at: i) at: anInteger)].
  ^cArray
 
It was previously going through a further indirection using the atPoint:
method, but this fails when the table is transposed.

Bye for now,
Aran
-- 
Aran Lunzer                              aran@dcs.glasgow.ac.uk
Department of Computing Science          Tel: +44 (0)141 339 8855 x8330
University of Glasgow                    Fax: +44 (0)141 330 4913
Glasgow G12 8QQ, Scotland   
