
miller
User
Mar 25, 2011, 2:07 PM
Post #2 of 2
(1055 views)
|
|
Re: [Tehmina Iqbal] need help in running this VSM code
[In reply to]
|
Can't Post
|
|
You're attempting to create a class without specifying a package name. Read the following tutorial: http://perldoc.perl.org/perltoot.html
my $engine = new( docs => \@docs, threshold => .04); ... # new sub new { my ( $class, %params ) = @_; should probably be changed to
my $engine = MyClassName->new( docs => \@docs, threshold => .04); ... package MyClassName; # new sub new { my ( $class, %params ) = @_; - Miller
|