Include a file: Difference between revisions

Content added Content deleted
(Updated example to compile with Nim 1.4. Added text about include statement.)
m (Corrected text.)
Line 1,754: Line 1,754:


=={{header|Nim}}==
=={{header|Nim}}==
As other modular languages, in a module accessing to symbols of other modules is done by importation.<br/>
As other modular languages, accessing from a module to symbols of other modules is done by importation.<br/>
After <code>import someModule</code> an exported symbol <code>x</code> can be accessed as <code>x</code> and as <code>someModule.x</code>.
After <code>import someModule</code> an exported symbol <code>x</code> can be accessed as <code>x</code> and as <code>someModule.x</code>.
<lang nim>import someModule
<lang nim>import someModule