Skip to content

[Debugger][P12] Recompiling code within a bloc cannot be done more than once in the debugger #722

@adri09070

Description

@adri09070

If you have a bloc closure like this, called via a method

MyClass>>mySortBlock

	^ [ :a :b | a < b ]

Then, you can paste this code in a playground and debug it (with one stepOver and one stepInto:

anObject := MyClass new.
anObject mySortBlock value: 1 value: 2

In the debugger, try to modify the code of the bloc, for example by adding a halt:

MyClass>>mySortBlock

      ^ [ :a :b | self halt.  a < b ]

and save the changes.

A popup will open, click on "Compile and browse".

A browser will then open on the embedding method with the new code:

image

Close this browser.

Then, in the debugger, change the code in the bloc again, for example by commenting the halt you've just added:

MyClass>>mySortBlock

      ^ [ :a :b | "self halt."  a < b ]

Save the changes, confirm the popup by clicking "compile and browse".

A browser opens on the method that hasn't been modified: the halt isn't commented:

image

Expected behavior:

The method should have been recompiled with the new code (i.e: with the commented halt)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions