raz / commit 69d40f8f

commit
69d40f8faeb84833c114e69529c8be1f2909b167
author
Luis <42945842+ldiaz94@users.noreply.github.com>
date
parent
f7a42c4d
site: v0.21.0

Its tarball, made from the tag by make dist, and download/latest; the
pages that show raz's output say what 0.21.0 prints.

patch · log

6 files changed, +16 -15

site/public/_redirects (history) modified +1 -1

@@ -1 +1 @@
1-/download/latest /download/raz-0.20.0-linux-x86_64.tar.gz 302
1+/download/latest /download/raz-0.21.0-linux-x86_64.tar.gz 302

site/public/advanced/static.html (history) modified +5 -5

@@ -97,8 +97,8 @@
9797 Cprint: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, with debug_info, not stripped
9898 <span class="cmd">$ ldd Cprint | sed &#x27;s/ (0x[0-9a-f]*)//&#x27;</span>
9999 linux-vdso.so.1
100- libc.so.6 =&gt; /lib/x86_64-linux-gnu/libc.so.6
101- /lib64/ld-linux-x86-64.so.2</code></pre>
100+ libc.so.6 =&gt; /usr/lib/libc.so.6
101+ /lib64/ld-linux-x86-64.so.2 =&gt; /usr/lib64/ld-linux-x86-64.so.2</code></pre>
102102 <p>Both are fine. The point is that you choose, and the language says which you chose: a program uses C exactly when a module of it has an <code>extern</code> or a <code>link</code> of a library.</p>
103103 <h2>Only what is reached</h2>
104104 <p>The compiler keeps only what can be reached from <code>main</code> and the module bodies. Unused procedures, variables and strings are left out. Here are two programs that differ by one large procedure that nothing calls.</p>
@@ -134,14 +134,14 @@
134134 <pre class="output term"><code><span class="cmd">$ raz Lean.raz</span>
135135 <span class="cmd">$ raz Heavy.raz</span>
136136 <span class="cmd">$ ls -l Lean Heavy | awk &#x27;{print $9, $5}&#x27;</span>
137-Heavy 28480
138-Lean 28472</code></pre>
137+Heavy 28488
138+Lean 28480</code></pre>
139139 <p>The sizes differ by a few bytes, not by the hundreds of kilobytes that the table and the procedure would take: they are not in the executable at all. You can link in a library module without worrying what else it offers.</p>
140140 <h2>Stripping</h2>
141141 <p><code>-s</code> leaves out what is there for finding faults: the symbols and line numbers, the places a failure is told by, and the profiler. It is for the final build of a size-conscious program; the default keeps them so that gdb and failure messages work.</p>
142142 <pre class="output term"><code><span class="cmd">$ raz -s -o Lean-stripped Lean.raz</span>
143143 <span class="cmd">$ ls -l Lean Lean-stripped | awk &#x27;{print $9, $5}&#x27;</span>
144-Lean 28472
144+Lean 28480
145145 Lean-stripped 6856
146146 <span class="cmd">$ ./Lean-stripped</span>
147147 same program</code></pre>

site/public/download/raz-0.21.0-linux-x86_64.tar.gz (history) added

Binary file; the patch has it.

site/public/download/raz-0.21.0-linux-x86_64.tar.gz.sha256 (history) added +1 -0

@@ -0,0 +1 @@
1+a8e2e550e927050d36a7e9731e6de22b094189adea15a984cd921917cbd8d90f raz-0.21.0-linux-x86_64.tar.gz

site/public/index.html (history) modified +8 -8

@@ -114,24 +114,24 @@
114114 <a href="raz-lib.pdf">the library</a>.</p>
115115
116116 <h2 id="download">Download</h2>
117-<p>raz 0.20.0 is a tarball for x86-64 Linux with the compiler, <code>raz</code>,
117+<p>raz 0.21.0 is a tarball for x86-64 Linux with the compiler, <code>raz</code>,
118118 its library, <code>lib/</code>, which it finds beside itself, the formatter
119119 and the documentation tool as sources in <code>tools/</code>, and the manual
120120 pages. It needs nothing else installed.</p>
121121 <div class="cta">
122- <a class="btn primary" href="download/raz-0.20.0-linux-x86_64.tar.gz">Download raz 0.20.0</a>
123- <a class="btn" href="download/raz-0.20.0-linux-x86_64.tar.gz.sha256">SHA-256</a>
122+ <a class="btn primary" href="download/raz-0.21.0-linux-x86_64.tar.gz">Download raz 0.21.0</a>
123+ <a class="btn" href="download/raz-0.21.0-linux-x86_64.tar.gz.sha256">SHA-256</a>
124124 </div>
125-<pre class="code"><code>$ tar xzf raz-0.20.0-linux-x86_64.tar.gz
126-$ ln -s $PWD/raz-0.20.0-linux-x86_64/raz ~/.local/bin/raz
125+<pre class="code"><code>$ tar xzf raz-0.21.0-linux-x86_64.tar.gz
126+$ ln -s $PWD/raz-0.21.0-linux-x86_64/raz ~/.local/bin/raz
127127 $ raz run Hello.raz</code></pre>
128128 <p>The link works since raz finds <code>lib/</code> beside its real path. The
129129 manual pages are in <code>man/</code>: <code>man ./man/raz-tutorial.7</code>.
130130 The address <code>download/latest</code> always leads to the newest release,
131-and <code>download/raz-0.20.0-linux-x86_64.tar.gz</code> to this one, for
132-good. Earlier releases: <a href="download/raz-0.19.0-linux-x86_64.tar.gz">0.19.0</a>, <a href="download/raz-0.18.1-linux-x86_64.tar.gz">0.18.1</a>, <a href="download/raz-0.18.0-linux-x86_64.tar.gz">0.18.0</a>, <a href="download/raz-0.17.2-linux-x86_64.tar.gz">0.17.2</a>, <a href="download/raz-0.17.1-linux-x86_64.tar.gz">0.17.1</a>, <a href="download/raz-0.17.0-linux-x86_64.tar.gz">0.17.0</a>, <a href="download/raz-0.16.0-linux-x86_64.tar.gz">0.16.0</a>, <a href="download/raz-0.15.0-linux-x86_64.tar.gz">0.15.0</a>, <a href="download/raz-0.14.0-linux-x86_64.tar.gz">0.14.0</a>, <a href="download/raz-0.13.0-linux-x86_64.tar.gz">0.13.0</a>, <a href="download/raz-0.12.0-linux-x86_64.tar.gz">0.12.0</a>, <a href="download/raz-0.11.1-linux-x86_64.tar.gz">0.11.1</a>, <a href="download/raz-0.11.0-linux-x86_64.tar.gz">0.11.0</a>, <a href="download/raz-0.10.1-linux-x86_64.tar.gz">0.10.1</a>, <a href="download/raz-0.10.0-linux-x86_64.tar.gz">0.10.0</a>, <a href="download/raz-0.9.1-linux-x86_64.tar.gz">0.9.1</a>, <a href="download/raz-0.9.0-linux-x86_64.tar.gz">0.9.0</a>, <a href="download/raz-0.8.0-linux-x86_64.tar.gz">0.8.0</a>, <a href="download/raz-0.7.1-linux-x86_64.tar.gz">0.7.1</a>; each has its SHA-256 beside it, with
131+and <code>download/raz-0.21.0-linux-x86_64.tar.gz</code> to this one, for
132+good. Earlier releases: <a href="download/raz-0.20.0-linux-x86_64.tar.gz">0.20.0</a>, <a href="download/raz-0.19.0-linux-x86_64.tar.gz">0.19.0</a>, <a href="download/raz-0.18.1-linux-x86_64.tar.gz">0.18.1</a>, <a href="download/raz-0.18.0-linux-x86_64.tar.gz">0.18.0</a>, <a href="download/raz-0.17.2-linux-x86_64.tar.gz">0.17.2</a>, <a href="download/raz-0.17.1-linux-x86_64.tar.gz">0.17.1</a>, <a href="download/raz-0.17.0-linux-x86_64.tar.gz">0.17.0</a>, <a href="download/raz-0.16.0-linux-x86_64.tar.gz">0.16.0</a>, <a href="download/raz-0.15.0-linux-x86_64.tar.gz">0.15.0</a>, <a href="download/raz-0.14.0-linux-x86_64.tar.gz">0.14.0</a>, <a href="download/raz-0.13.0-linux-x86_64.tar.gz">0.13.0</a>, <a href="download/raz-0.12.0-linux-x86_64.tar.gz">0.12.0</a>, <a href="download/raz-0.11.1-linux-x86_64.tar.gz">0.11.1</a>, <a href="download/raz-0.11.0-linux-x86_64.tar.gz">0.11.0</a>, <a href="download/raz-0.10.1-linux-x86_64.tar.gz">0.10.1</a>, <a href="download/raz-0.10.0-linux-x86_64.tar.gz">0.10.0</a>, <a href="download/raz-0.9.1-linux-x86_64.tar.gz">0.9.1</a>, <a href="download/raz-0.9.0-linux-x86_64.tar.gz">0.9.0</a>, <a href="download/raz-0.8.0-linux-x86_64.tar.gz">0.8.0</a>, <a href="download/raz-0.7.1-linux-x86_64.tar.gz">0.7.1</a>; each has its SHA-256 beside it, with
133133 <code>.sha256</code> added to its name.</p>
134-<p class="sha">SHA-256 <code>bfa954d27d759e4ca7f7f33debb4705f25d5c05a097d86aa28b3260048b5d9cc</code></p>
134+<p class="sha">SHA-256 <code>a8e2e550e927050d36a7e9731e6de22b094189adea15a984cd921917cbd8d90f</code></p>
135135 <p><a href="source/releases/index.html">Release pages</a> give each
136136 version's commit, notes, compiler and source archives, with checksums.
137137 Browse the <a href="source/index.html">source and history</a>, or clone:

site/public/tour/hello.html (history) modified +1 -1

@@ -70,7 +70,7 @@
7070 <span class="cmd">$ raz run Quiet.raz</span>
7171 hello, again
7272 <span class="cmd">$ ls -l Quiet | awk &#x27;{print $5, &quot;bytes&quot;}&#x27;</span>
73-28472 bytes</code></pre>
73+28480 bytes</code></pre>
7474 <p>The program is a static executable with no run time besides the code it uses, so it is a few kilobytes, and runs without any library installed.</p>
7575 <h2>What <code>Out</code> can write</h2>
7676 <p><code>Out</code> is the library's buffered output. It writes strings, single characters, numbers in decimal or hexadecimal, and a line feed. A string is written as it is, with <code>\n</code> for a line feed, <code>\t</code> for a tab, <code>\"</code> and <code>\\</code>; or between backquotes, as a raw string with no escapes at all, which may run over lines (lesson 6).</p>