summaryrefslogtreecommitdiffstats
path: root/articles/xerl-0.2-two-modules/index.html
diff options
context:
space:
mode:
Diffstat (limited to 'articles/xerl-0.2-two-modules/index.html')
-rw-r--r--articles/xerl-0.2-two-modules/index.html14
1 files changed, 9 insertions, 5 deletions
diff --git a/articles/xerl-0.2-two-modules/index.html b/articles/xerl-0.2-two-modules/index.html
index a6071cbf..e2da8c4b 100644
--- a/articles/xerl-0.2-two-modules/index.html
+++ b/articles/xerl-0.2-two-modules/index.html
@@ -72,7 +72,7 @@
<p>Everything is an expression.</p>
<p>This sentence carries profound meaning. We will invoke it many times over the course of these articles.</p>
<p>If everything is an expression, then the language shouldn&apos;t have any problem with me defining two modules in the same source file.</p>
-<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.8
+<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.9
by Lorenzo Bettini
http://www.lorenzobettini.it
http://www.gnu.org/software/src-highlite -->
@@ -85,7 +85,7 @@ http://www.gnu.org/software/src-highlite -->
<b><font color="#0000FF">end</font></b></tt></pre>
</div></div>
<p>Likewise, it shouldn&apos;t have any problem with me defining a module inside another module.</p>
-<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.8
+<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.9
by Lorenzo Bettini
http://www.lorenzobettini.it
http://www.gnu.org/software/src-highlite -->
@@ -102,7 +102,7 @@ http://www.gnu.org/software/src-highlite -->
<p>If everything is an expression, does that mean this will allow me to create modules at runtime using the same syntax? Yes, but let&apos;s not get ahead of ourselves yet.</p>
<p>For now we will just iterate over the AST, and will compile a module for each <code>mod</code> found. Modules cannot contain expressions yet, so there&apos;s no need to recurse over it at this point. This should solve the compilation of our first snippet.</p>
<p>The <code>compile/1</code> function becomes:</p>
-<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.8
+<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.9
by Lorenzo Bettini
http://www.lorenzobettini.it
http://www.gnu.org/software/src-highlite -->
@@ -126,7 +126,7 @@ http://www.gnu.org/software/src-highlite -->
<b><font color="#000000">execute</font></b>(<font color="#009900">Filename</font>, <font color="#009900">Tail</font>, [<font color="#009900">Name</font>|<font color="#009900">Modules</font>])<font color="#990000">.</font></tt></pre>
</div></div>
<p>Running this compiler over the first snippet yields the following result:</p>
-<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.8
+<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.9
by Lorenzo Bettini
http://www.lorenzobettini.it
http://www.gnu.org/software/src-highlite -->
@@ -159,7 +159,7 @@ http://www.gnu.org/software/src-highlite -->
{<font color="#FF6600">ok</font>,[<font color="#FF6600">first_module</font>,<font color="#FF6600">second_module</font>]}</tt></pre>
</div></div>
<p>Everything looks fine. And we can check that the two modules have been loaded into the VM:</p>
-<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.8
+<div class="listingblock"><div class="content"><!-- Generator: GNU source-highlight 3.1.9
by Lorenzo Bettini
http://www.lorenzobettini.it
http://www.gnu.org/software/src-highlite -->
@@ -197,6 +197,10 @@ http://www.gnu.org/software/src-highlite -->
+ <li><a href="https://ninenines.eu/articles/cowboy-2.7.0/">Cowboy 2.7</a></li>
+
+
+
<li><a href="https://ninenines.eu/articles/gun-2.0.0-pre.1/">Gun 2.0 pre-release 1</a></li>