14 use open qw( :utf8 :std );
24 join(" ", sort @{mro::get_isarev $args[0]}),
25 join(" ", sort @args[1..$#args-1]),
31 # Basic isarev updating, when @ISA changes
32 @팟tРṉ::ISA = "B옫yპt::ぅงலҬ";
33 @S추ঋ::ISA = "B옫yპt::ぅงலҬ";
34 @B옫yპt::ぅงலҬ::ISA = "B옫yპt";
35 i B옫yპt => qw [ B옫yპt::ぅงலҬ 팟tРṉ S추ঋ ],
36 'subclasses and subsubclasses are added to isarev';
38 i B옫yპt => qw [ B옫yპt::ぅงலҬ S추ঋ ],
39 'single deletion from isarev';
40 @B옫yპt::ぅงலҬ::ISA = ();
41 i B옫yპt => qw [ ], 'recursive deletion from isarev';
42 # except underneath it is not actually recursive
45 # More complicated tests that move packages around
50 @솜ェ::ƀ란ƌ::ᚿamㅔ::ISA = "독::ㄅ";
52 @Frȇe::팀ẽ::ISA = "TレӔṪ";
53 @My촐ꡙʳ::ISA = "독::ցളŔ::Leaʇhㄦ";
54 @독::ցളŔ::Leaʇhㄦ::ISA = "ցളŔ";
55 @AŇℴtḫeᕃ::ցളŔ::ISA = "ցളŔ";
59 "deleting a stash elem updates isarev entries";
60 i TレӔṪ=>qw[ Frȇe::팀ẽ 팈ዕ::ㄅ ],
61 "deleting a nested stash elem updates isarev entries";
62 i ցളŔ=>qw[ AŇℴtḫeᕃ::ցളŔ 팈ዕ::ցളŔ::Leaʇhㄦ ],
63 "deleting a doubly nested stash elem updates isarev entries";
66 @ごଅt::DଐɾẎ::ISA = "ごଅt";
67 @ごଅt::DଐɾẎ::Ⱦ옥ゲᕟƃᚒḠ::ISA = "ごଅt::DଐɾẎ";
68 @웨ɪrƌ::ጢᶯᵷ::ISA = "g";
70 i ごଅt => qw[ ごଅt::DଐɾẎ ごଅt::DଐɾẎ::Ⱦ옥ゲᕟƃᚒḠ 웨ɪrƌ::ጢᶯᵷ ],
71 "isarev includes subclasses of aliases";
73 i ぅงலҬ => qw[ ごଅt ごଅt::DଐɾẎ ごଅt::DଐɾẎ::Ⱦ옥ゲᕟƃᚒḠ ],
74 "deleting an alias to a package updates isarev entries";
75 i"ごଅt" => qw[ ごଅt::DଐɾẎ ごଅt::DଐɾẎ::Ⱦ옥ゲᕟƃᚒḠ ],
76 "deleting an alias to a package updates isarev entries of nested stashes";
77 i"ごଅt::DଐɾẎ" => qw[ ごଅt::DଐɾẎ::Ⱦ옥ゲᕟƃᚒḠ ],
78 "deleting an stash alias updates isarev entries of doubly nested stashes";
79 i g => qw [ 웨ɪrƌ::ጢᶯᵷ ],
80 "subclasses of the deleted alias become part of its isarev";
82 @챂린ẽ::ISA = "Hഓf엗::맘말";
83 @챂린ẽ::DଐɾẎ::ISA = "챂린ẽ";
84 @챂린ẽ::DଐɾẎ::Obェʶ핫l::ISA = "챂린ẽ::DଐɾẎ";
85 @ẂhaƮᵋቭȓ::ISA = "챂린ẽ";
88 i"Hഓf엗::맘말" => qw[ 챂릳 ],
89 "replacing a stash updates isarev entries";
90 i ㄔɘvレ => qw[ 챂릳::DଐɾẎ ẂhaƮᵋቭȓ ],
91 "replacing nested stashes updates isarev entries";
93 @ᛑiስアsઍ::ェᔦ::ISA = "ᛑiስアsઍ";
94 @ᛑiስアsઍ::ェᔦ::Iṇᚠctĭo웃::ISA = "ᛑiስアsઍ::ェᔦ";
95 @Kㄦat옻onj운ctᝁヸቲᔈ::ISA = "ᛑiስアsઍ::Opɥt할및::Iṇᚠctĭo웃";
96 *ᛑiስアsઍ::Opɥt할및:: = *ᛑiስアsઍ::ェᔦ::;
97 {package 솜e_란돔_new_symbol::Iṇᚠctĭo웃} # autovivify
98 *ᛑiስアsઍ::Opɥt할및:: = *솜e_란돔_new_symbol::;
99 i ᛑiስアsઍ => qw[ ᛑiስアsઍ::ェᔦ ᛑiስアsઍ::ェᔦ::Iṇᚠctĭo웃 ],
100 "replacing an alias of a stash updates isarev entries";
101 i"ᛑiስアsઍ::ェᔦ" => qw[ ᛑiስアsઍ::ェᔦ::Iṇᚠctĭo웃 ],
102 "replacing an alias of a stash containing another updates isarev entries";
103 i"솜e_란돔_new_symbol::Iṇᚠctĭo웃" => qw[ Kㄦat옻onj운ctᝁヸቲᔈ ],
104 "replacing an alias updates isarev of stashes nested in the replacement";
106 # Globs ending with :: have autovivified stashes in them by default. We
107 # want one without a stash.
110 @눌Ļ::눌Ļ::ISA = "Eṁptᔾ::Eṁptᔾ";
111 {package ዚlcᕻ::Eṁptᔾ} # autovivify it
113 i ዚlcᕻ => qw[ 눌Ļ ], "assigning to an empty spot updates isarev";
114 i"ዚlcᕻ::Eṁptᔾ" => qw[ 눌Ļ::눌Ļ ],
115 "assigning to an empty spot updates isarev of nested packages";
117 # Classes inheriting from multiple classes that get moved in a single
119 @ᕘ::ISA = ("ᵇ", "ᵇ::ᵇ");
121 my $अ = \%अ::; # keep a ref
122 *अ:: = 'whatever'; # clobber it
123 *ᵇ:: = $अ; # assign to two superclasses of ᕘ at the same time
124 # There should be no अ::ᵇ isarev entry.
125 i"अ::ᵇ" => qw [], 'assigning to two superclasses at the same time';
127 "A class must not inherit from its superclass’s former name";
131 $_ = \*α::ISA; # hang on to the glob
133 i β => qw [], "undeffing an ISA glob deletes isarev entries";
137 i 붘ㆉ => qw [], "undeffing a package glob deletes isarev entries";
139 # Package aliasing/clobbering when the clobbered package has grandchildren
142 @숩Ȼl았A::ISA = "숩Ȼl았Ƃ";
146 'clobbering a class w/multiple layers of subclasses updates its parent';
150 i S민 => qw [], '%Package:: list assignment';