| Subject: | List with qw and without |
|---|---|
| From: | esia168@xxxxxxxxx (William) |
| Date: | Sat, 26 Jul 2008 02:50:44 -0700 (PDT) |
| Newsgroups: | perl.beginners |
package MyConfig; use constant (DOCUMENT_ROOT => "/var/www/"); require Exporter; our @ISA = qw(Exporter); our @EXPORT_OK = qw(DOCUMENT_ROOT); # This works #our @EXPORT_OK = (DOCUMENT_ROOT); # But this does not work 1; use MyConfig qw(DOCUMENT_ROOT); print DOCUMENT_ROOT; # If I do not use qw , I will get error of "DOCUMENT_ROOT" is not exported by the MyConfig module # Why is qw importance is so significance here ? # I thought qw is just a syntatic sugar of perl to make a list # Thank you. Send instant messages to your online friends http://uk.messenger.yahoo.com |
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: XS, Patrick Dupre |
|---|---|
| Next by Date: | Re: List with qw and without, Rob Dixon |
| Previous by Thread: | while trying to learn pack, Richard Lee |
| Next by Thread: | Re: List with qw and without, Rob Dixon |
| Indexes: | [Date] [Thread] [Top] [All Lists] |