<?xml version="1.0" encoding="windows-1252"?>
<node id="1015841" title="Re: Difference between use Module::Name and use Module::Name qw /method1 method2/" created="2013-01-29 05:10:10" updated="2013-01-29 05:10:10">
<type id="11">
note</type>
<author id="708738">
LanX</author>
<data>
<field name="doctext">
From what I can see from the source of [MOD://Algorithm::LUHN] nothing is exported by default:
&lt;c&gt;
@EXPORT    = qw//;
@EXPORT_OK = qw/check_digit is_valid valid_chars/;
&lt;/c&gt;&lt;P&gt;&lt;P&gt;

so if you wanna import &lt;C&gt;is_valid&lt;/C&gt; you need to tell explicitly.&lt;P&gt;&lt;P&gt;

see also [doc://Exporter#How-to-Export]&lt;P&gt;&lt;P&gt;

&lt;H5&gt; EDIT&lt;P&gt;&lt;/H5&gt;&lt;P&gt;

&lt;I&gt;&amp;gt; Is it somehow better to use the second statement if I use only "is_valid" method in my code? Maybe, memory issues or something?&lt;/I&gt;&lt;P&gt;&lt;P&gt;

No! No significant memory problems, importing is a kind of aliasing between namespaces.&lt;P&gt;&lt;P&gt;

But you have to care about potential &lt;i&gt;namespace polution&lt;/i&gt;, see [doc://Exporter#Selecting-What-To-Export].&lt;P&gt;&lt;P&gt;

Please note that you don't necessarily need to import &lt;C&gt;is_valid&lt;/C&gt;, otherwise can also address &lt;C&gt;Algorithm::LUHN::is_valid&lt;/C&gt; directly.
 
&lt;!-- Node text goes above. Div tags should contain sig only --&gt;
&lt;div class="pmsig"&gt;&lt;div class="pmsig-708738"&gt;
&lt;p&gt;Cheers Rolf
&lt;/div&gt;&lt;/div&gt;</field>
<field name="root_node">
1015838</field>
<field name="parent_node">
1015838</field>
</data>
</node>
