[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: success/feedback
From: |
Paul Johnson |
Subject: |
Re: success/feedback |
Date: |
Tue, 18 Jan 2000 10:19:28 -0600 |
Ralf Stephan wrote:
>
> Here is one datapoint for you. The time needed for building a first
> model was about 20 hours. No prior working experience with Swarm or
> ObjC, but years of C and gdb, as well as OOP. No outside help apart
> from documentation, code, and an ObjC online book.
>
> http://www.in-berlin.de/User/rws/swarm.html
>
> This is a very crude, of course, and debatable model (see README).
> Most of the time was spent hunting a few idiotic bugs, and I had to
> use gdb plus common sense extensively. No major problems with Swarm
> was found but I have a few picks/ideas:
>
> - when messages are going into nirvana, there should be a fast way,
> esp. for beginners, to see if it's the object or the selector.
> - of course, it's a big no-no to change members of an ActionForEach
> while executing it, so I immediately stepped into that. Finding
> the bug was horrible (at the end I commented out whole chunks of
> code), and it reminded me vividly of my first stack overflow.
> - uninitialized pointers don't always seem to contain 0x0, so one can't
> be sure if it's memory corruption. So there is no way out of
> defensive programming.
Thanks for the feedback. My estimate agrees with yours. FOr experienced
programmers, Swarm and Obj-C do not present massive hurdles. For the
people enticed into programming by Swarm, the hurdles are sharper.
WHen I run your program, I get a lot of these:
*** event raised for warning: WarningMessage
Grid2d: you're overwriting object 8175de8 at (27,22) with object
8174268.
Grid2d does not support two objects in one place.
*** execution continuing...
*** event raised for warning: WarningMessage
Grid2d: you're overwriting object 8174318 at (64,92) with object
8174d10.
Grid2d does not support two objects in one place.
*** execution continuing...
THis creates a memory leak and makes the simulation difficult to
interpret.
Sven T wrote a class that he put in a package called "svenSpaces" as I
recall, and it had a Grid2d in which multiple occupancy was permitted.
I did some revamping to allow the elements in the Grid to serve more
general purposes, that's in
http://lark.cc.ukans.edu/~pauljohn/Swarm/MySwarmCode/WrappedListGrid2d-990817.tar.gz
--
Paul E. Johnson email: address@hidden
Dept. of Political Science http://lark.cc.ukans.edu/~pauljohn
University of Kansas Office: (785) 864-9086
Lawrence, Kansas 66045 FAX: (785) 864-5700
==================================
Swarm-Support is for discussion of the technical details of the day
to day usage of Swarm. For list administration needs (esp.
[un]subscribing), please send a message to <address@hidden>
with "help" in the body of the message.
- success/feedback, Ralf Stephan, 2000/01/18
- Re: success/feedback,
Paul Johnson <=