560 |
560 |
561 ! ! |
561 ! ! |
562 |
562 |
563 !ClassDescription methodsFor:'Compatibility - ST80'! |
563 !ClassDescription methodsFor:'Compatibility - ST80'! |
564 |
564 |
|
565 addInstVarName:anotherInstVar |
|
566 |sel newClass args| |
|
567 |
|
568 sel := self definitionSelector. |
|
569 Class nameSpaceQuerySignal answer:(self nameSpace) |
|
570 do:[ |
|
571 args := Array |
|
572 with:(self name) |
|
573 with:(self instanceVariableString , ' ' , anotherInstVar) |
|
574 with:(self classVariableString) |
|
575 with:'' |
|
576 with:(self category). |
|
577 |
|
578 sel numArgs == 6 ifTrue:[ |
|
579 args := args copyWith:(self owner). |
|
580 ]. |
|
581 |
|
582 newClass := self superclass |
|
583 perform:sel withArguments:args. |
|
584 |
|
585 "/ "/ copy over methods ... |
|
586 "/ self class copyInvalidatedMethodsFrom:self class for:newClass class. |
|
587 "/ self class copyInvalidatedMethodsFrom:self for:newClass. |
|
588 "/ newClass class recompileInvalidatedMethods. |
|
589 "/ newClass recompileInvalidatedMethods. |
|
590 ]. |
|
591 |
|
592 "/ owner changed:#newClass with:newClass. |
|
593 "/ Smalltalk changed:#newClass with:newClass. |
|
594 |
|
595 "/ self removeFromSystem. |
|
596 |
|
597 ^ newClass |
|
598 ! |
|
599 |
565 organization |
600 organization |
566 "for ST80 compatibility; |
601 "for ST80 compatibility; |
567 read the documentation in ClassOrganizer for more info." |
602 read the documentation in ClassOrganizer for more info." |
568 |
603 |
569 ^ ClassOrganizer for:self |
604 ^ ClassOrganizer for:self |
|
605 ! |
|
606 |
|
607 removeInstVarName:anInstVar |
|
608 |sel newClass args newNames| |
|
609 |
|
610 newNames := self instVarNames. |
|
611 newNames remove:anInstVar ifAbsent:[^ self]. |
|
612 |
|
613 sel := self definitionSelector. |
|
614 Class nameSpaceQuerySignal answer:(self nameSpace) |
|
615 do:[ |
|
616 args := Array |
|
617 with:(self name) |
|
618 with:(newNames asStringWith:Character space) |
|
619 with:(self classVariableString) |
|
620 with:'' |
|
621 with:(self category). |
|
622 |
|
623 sel numArgs == 6 ifTrue:[ |
|
624 args := args copyWith:(self owner). |
|
625 ]. |
|
626 |
|
627 newClass := self superclass |
|
628 perform:sel withArguments:args. |
|
629 |
|
630 "/ "/ copy over methods ... |
|
631 "/ self class copyInvalidatedMethodsFrom:self class for:newClass class. |
|
632 "/ self class copyInvalidatedMethodsFrom:self for:newClass. |
|
633 "/ newClass class recompileInvalidatedMethods. |
|
634 "/ newClass recompileInvalidatedMethods. |
|
635 ]. |
|
636 |
|
637 "/ owner changed:#newClass with:newClass. |
|
638 "/ Smalltalk changed:#newClass with:newClass. |
|
639 |
|
640 "/ self removeFromSystem. |
|
641 |
|
642 ^ newClass |
570 ! |
643 ! |
571 |
644 |
572 reorganizeFromString:orgString |
645 reorganizeFromString:orgString |
573 "for ST80 compatibility but without functionality" |
646 "for ST80 compatibility but without functionality" |
574 |
647 |