Oops, that still leaves the issue of ~~. Well, seeing as it's a broken experimental feature, best if you simply avoid it!
Not only that, your smart-match version is far less efficient. Use one of the following:
or# Unordered my %diff; @diff{ @insttab } = (); delete @diff{ @inst }; my @diff = keys %diff;
# Ordered my %in_inst; @in_inst{ @inst } = (); my @diff = grep { !exists($in_inst{$_}) } @insttab;
Both are O(N+M) (as opposed to the O(N*M) smartmatching approach).
Generally speaking, you'd want two different modules with the same interface in that situation. Simply load the correct module using if (the module).
In reply to Re^2: compilation error on 5.8 with $^V gt 'v5.10.0'
by ikegami
in thread compilation error on 5.8 with $^V gt 'v5.10.0'
by gabrielsousa
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |