overloading-0.01 > overloading
名前¶
overloading - perl pragma to lexically control overloading
overloading - レキシカルにオーバーロードを制御する perl プラグマ
概要¶
{
no overloading;
my $str = "$object"; # doesn't call stringification overload
}
# it's lexical, so this stringifies:
warn "$object";
# it can be enabled per op
no overloading qw("");
warn "$object";
# and also reenabled
use overloading;
説明¶
This pragma allows you to lexically disable or enable overloading.
このプラグマはオーバーロードをレキシカルに無効または有効にします。
no overloading-
Disables overloading entirely in the current lexical scope.
現在のレキシカルスコープでオーバーロードを完全に無効にします。
no overloading @ops-
Disables only specific overloads in the current lexical scope.
現在のレキシカルスコープで指定されたオーバーロードだけを無効にします。
use overloading-
Reenables overloading in the current lexical scope.
現在のレキシカルスコープでオーバーロードを再有効化します。
use overloading @ops-
Reenables overloading only for specific ops in the current lexical scope.
現在のレキシカルスコープで指定された演算子についてのみオーバーロードを 再有効化します。