On Fri, Oct 6, 2017 at 6:15 PM, Dirk Olmes <d...@xanthippe.ping.de> wrote:
> Hi, > > I may be asking an absolute noob question but I was unable to find any > useful hints on google ... > > I often find myself writing methods that do not yet exist when > implementing other methods, e.g. when I'm writing the implementation of > methodA I'm calling out to methodB. > > What's the easiest way to create the new method? I know I can jump > aroung through hoops with a separate browser but that feels cumbersome. > > I understand that the editor/runtime/whatever cannot know 100% of the > time where to put the new method but at least for messages to self it > should be smart enough to offer some kind of help. > > -dirk > > A common Pharo workflow is known as "programming from within the debugger." Run your #methodA code as soon as possible, and when the debugger pops up because someObject hasn't yet implemented #methodB, the debugger helps you create #methodB in the right place. Some examples... * https://www.youtube.com/watch?v=ymITEeAOtEA * http://www.virtuouscode.com/2015/05/11/in-which-i-make-you-hate-ruby-in-7-minutes/ Give it a go and stick with it for a while, and you'll understand why Smalltalk invented Test Driven Development (and it may change they way you think about programming.) cheers -ben