Unit values

Brian Rice water at tunes.org
Wed Apr 27 16:52:23 PDT 2005


Sorry, I'm really stressed right now trying to adapt Slate for 
concurrency, and can't seem to create an environment where I can 
concentrate at all lately. It's fine to just send out ideas, but 
honestly please think around the problem first. I only ask that you 
quit including the full text of every mail in the past 4 replies on a 
thread with every response, and to take time to explain what you want 
in the abstract without obscuring it with concrete slot-munging - 
despite the fact that you can do anything by creating an arbitrary 
structure of Slate objects and slots between them, this is a little 
like trying to do everything in Perl with a regular expression and its 
associated punctuation operators.

> It's a minimal example of how you'd implement the solution I proposed.
> I guess I was under the mistaken impression that being able to 
> override behaviour (like printing) for values of specific units was a 
> reasonable way to use Slate.

> All i did was make sure all values of a specific Unit had a common 
> parent object, so I could use that common parent object to override 
> behaviour for all values of that unit. I tried to explain but i felt 
> that I wasn't getting through, since English is my second language I 
> thought that maybe I could explain it better to you if you saw the 
> results yourself.

This was not well-explained at all.

> I'm a bit confused about this, one minute you encourage me to make the 
> changes myself and submit patches and the next you ask me to stop 
> futzing with the library that is supposedly good enough as it is. 
> Could you then please explain how I would override printOn: for values 
> of a specific Unit cause i sure couldn't find a way.

Don't use printOn:, then! If a tool looks like it's hard to use, switch 
to another pattern. Look at how print.slate works - not every method is 
just a simple printOn:. Also, "printing XML" is not quite the right 
concept. The bottom line is that if you're doing pattern-matching style 
things in an object-oriented language, that you'll have to send 
messages to children and dispatch on them as you go. This is much less 
pronounced in Slate than Java (say), but it still must be done.

> If the level of this list is that high (that you have to review all 
> messages for several hours before posting) then that wasn't clearly 
> stated anywhere so I had no chance of knowing that. I'll take my 
> chances with this mail, though.

It isn't. See below...

> Don't expect anyone to be interested in helping out if you treat them 
> like dirt.

Sorry, but I need to get people to focus on writing real code by 
writing out standard-idiom code rather than introducing slot-munging 
code to hack at things they don't understand yet. The bottom line is 
that if you write in the standard idiom, it can be refactored using a 
language extension later (this happens repeatedly - but I want the code 
written in a standard way first and keep the speculation to a low 
minimum so it can be considered over at least >>>weeks<<< of time and 
not hours).

I yelled to get an effect, and because I wrote two replies and deleted 
them because I was so upset and was sick of this mailing list thread. I 
mean, seriously, we started with "Prevent cloning of clones", and all 
this is about dimensioned units! It's very frustrating to have a new 
user immediately ask for language hacks when they just need to get 
something very simple done that doesn't require them at all. I'm sorry 
you feel treated that way, but my fuse is short.

> Happy focusing!

It's not happy yet. :P

--
Brian T. Rice
LOGOS Research and Development
http://tunes.org/~water/




More information about the Slate mailing list