Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Be careful of setting breakpoints here, you'll crash your image :P

I accidentally defined `=` on a class with an incomplete implementation. I think I saved it just out of habit.

Of course, this royally buggered the entire image because the class browser evaluated `=` when trying to open that specific class.

I was doing this in Squeak rather than Pharo, but that was a scary moment when my mental model before that was to do a `git checkout` to revert the change. I think I ended up writing some code to find the method and delete it, before I realised there was a change browser where I could discard that implementation.

The biggest barrier to entry was really understanding the concept of the image and that you do all the work in the class browser, rather than building a hierarchy of classes that all branch out from a main class.

I had a lot of fun playing around with Smalltalk.



Hahaha, yep I can see how that would go wrong :')

> before I realised there was a change browser where I could discard that implementation.

Haha nice!

There's also a changes file.

I guess I have another recommendation: Pharo is not just about the image. When you click on an image folder there are other files. Try to figure out what they do and how you could use it to your advantage. Check out what the pharo-local folder does for example. The iceberg folder there, for example, directly hosts the .git folder. I've used it at times if I couldn't get whatever I wanted to do in Iceberg to work (e.g. adding a remote). The .sources file shows the changes that you have.


For sure. I started off with Squeak so I eventually got the git package installed and, in addition to updating the image and the changes file, it also wrote out the classes I added to disk - basically a directory being the class and every file inside the directory being the implementation of a method.

It's hard for me to see what I'd deploy this way, as a pet project, but it's teaching me a lot more about a nice way to do OOP that also gives you an environment in which OOP can thrive.




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: