Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: Very basic package / module question...

by CountZero (Bishop)
on Feb 05, 2010 at 16:28 UTC ( #821599=note: print w/replies, xml ) Need Help??


in reply to Very basic package / module question...

Welcome back to Perl!

Your problem is twofold:

  1. This module does not seem to be OO. It exports a function (hello) but not the constant GOODBYE;
  2. Your subroutine goodbye does not live in the SPEAK::ITALIAN package, so you could consider adding package SPEAK::ITALIAN; just bebfore your subroutine definition.
As from that place in your program all functions, constants, variables, ... will be considered to reside in the SPEAK::ITALIAN package unless you fully qualify them, as almut already said.

CountZero

A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://821599]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (3)
As of 2020-10-31 11:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My favourite web site is:












    Results (288 votes). Check out past polls.

    Notices?