SeasideSt / Seaside

The framework for developing sophisticated web applications in Smalltalk.
MIT License
519 stars 71 forks source link

Squeak has no #isImmediateObject #1389

Open timrowledge opened 1 year ago

timrowledge commented 1 year ago

This method is only used (in the context of a Squeak 6.1 trunk image with Seaside as of late October 2023) in Object>>#traverseWithMemory:seen: which is part of *Seaside-Pharo-Development.

Implementing the requisite 4 methods is trivial but I don't have a sure idea of which package etc they might be best placed in. Right now I just used *Seaside-Squeak-Core because it sound plausible. Sample methods offered herein -

Squeak-isImmediate.zip

marschall commented 4 months ago

#traverseWithMemory:seen: is sent by WAMemory to compute memory sizes of object graphs. #isImmediateObject should go to Seaside-Squeak-Development either a copy of Seaside-Pharo-Development or just extension methods. Given all the other Squeak specific issues like #1394 probably a full package makes sense.

It is debatable whether #isImmediateObject should go to Object or ProtoObject. You could also override #traverseWithMemory:seen: for immediate classes.

timrowledge commented 4 months ago

I think I like the idea of a Seaside-Squeak-Development package as an extension of the Pharo items.

I'd offer to do the work but

marschall commented 4 months ago

Roughly the workflow is:

  1. Fork Seaside and Grease on GitHub
  2. Clone the forks
  3. Create a git branch for you changes
  4. Load Seaside and Grease using something like
    
    Installer ensureRecentMetacello. 

Metacello new baseline: 'Grease'; repository: 'filetree:///home/timrowledge/git/Grease/repository'; fetch; load: 'ALL'.

Metacello image project: 'Grease'; lock.

Metacello new baseline: 'Seaside3'; onLock: [:ex :existing :new | ex honor ]; repository: 'filetree:///home/timrowledge/git/Seaside/repository'; fetch; load: 'CI'


5. Make your changes and save them using Monticello
6. Add them in git, commit them in git, push the feature branch
7. Open a pull request
timrowledge commented 4 months ago

Thanks for that suggestion; I haven't seen anyone mention that approach before. Last time I tried to commit anything for Seaside it took three of us an entire evening to make anything happen.

On 2024-07-06, at 2:22 AM, Philippe Marschall @.***> wrote:

Roughly the workflow is:

tim

tim Rowledge; @.***; http://www.rowledge.org/tim Useful random insult:- Thinks everyone else is entitled to his opinion, like it or not.