Calypso icon indicating copy to clipboard operation
Calypso copied to clipboard

Remove of referenced class should give user options what to do

Open dionisiydk opened this issue 6 years ago • 1 comments

https://pharo.fogbugz.com/f/cases/22375/Deleting-a-referenced-class-now-shows-debugger-before-giving-the-refactoring-dialog

dionisiydk avatar Oct 02 '18 19:10 dionisiydk

Remove class should ask user what to do if class have references. It should be similar to remove method command. But in case of class removal there are more warnings available. Imagine that there are no references but:

  1. what to do if class have subclasses?

Now we just remove a class silently and all subclasses are moved to superclass. But should not we show list of subclasses. It is possible that user is trying remove class which subclasses are in another package.

  1. what to do if subclasses use removal class variables?

Now we do not have any logic for this. Class is just removed and subclasses are staying with undeclares. I thing we can allow to browse variable references of removal class.

  1. what to do if class is a trait with users?

Nautilus ask user to browse users in that case but it never work. I think we can show users in query browser (it supports classes too).

  1. same as 2) but for trait users.

dionisiydk avatar Oct 02 '18 20:10 dionisiydk