これは恥ずかしい質問ですが、なぜこの行は機能するのに、他の行は機能しないのでしょうか。
作業ライン:
use strict;
use warning;
use Wx qw(:everything);
my $dialog = Wx::MessageDialog->new(
$self,
"About test\n" . "Version 0.01\n",
"About Test",
wxOK | wxCENTRE
);
非稼働ライン:
use strict;
use warning;
use Wx;
my $dialog = Wx::MessageDialog->new(
$self,
"About test\n" . "Version 0.01\n",
"About Test",
wxOK | wxCENTRE
);
動作していない回線からのエラーメッセージ:
Bareword "wxOK" not allowed while "strict subs" in use at test.pl line 123.
Bareword "wxCENTRE" not allowed while "strict subs" in use at test.pl line 123.
BEGIN not safe after errors--compilation aborted at test.pl line 348.