Reckoner Riddlelisting in Rust
Here’s a Rust Riddlelist that bids the world hello:
fn main() {
println!("Hello, World!");
}
Let us walk through the words of this riddlelist step by step and come to ken how it drives the reckoner to weave a greeting.
Do not — as some ungracious pastors do —
Show me the steep and thorny way to heaven,
Whilst, like a puffed and reckless libertine,
Himself the primrose path of dalliance treads,
And recks not his own rede.
- Ophelia to Laertes, Hamlet, Act I Scene 3
(Inspired by Poul Anderson’s Uncleftish Beholding.)
Wordcraft
fn main():
This is the inway of the Rust riddlelist. Runwork starts here.
The rune fn
marks a workflow,
and main
is the name of this workflow.
fn
is from the Frankish for workflow, function.
{ ... }
The curlwrappers hold the wordcraft that
makes up the body of the main
workflow.
println!("Hello, World!");
This row of our list shows the words "Hello World!"
on the showglass.
It calls upon the println!
inwoven-word,
which is built into the Rust Groundbookhold.
The name is self-kenning,
to those who speak a bit of Frankish: it print
s a l
in
e.
We might name it showrow
in our tongue.
We call upon println!
– or any inwoven-word or workflow – with roundwrappers.
A call shifts the steer of our riddlelist,
handing the tiller to the called workflow.
How It Unfolds
Builder
First, the Rust builder, rustc
, weaves
a riddlelist in the reckoner’s tongue
out of our fount wordcraft.
Reck that the c
in rustc
is from the Frankish for builder, compiler.
As it weaves, so also does the builder scrutinize our riddlelist. The forge marks kindrightness, wordhold-welfare (Rust is a tongue that cares much for wordhold-welfare, domain of the borrow-marker), and so forth.
These do not worry us now, for our riddlelist is so groundish. But the Rust builder is a mighty friend when riddlelists become more fiendish, and so a Rust riddlelister learns to reck its rede well and to heed its warnings.
The builder also reworks our inwoven-word, println!
,
into a workflow like our main
–
but we do not ever see this middle wordcraft.
rustc
makes a runnable twoname,
which we can then run on our reckoner.
Runwork
When we run the twoname the reckoner’s runwarden,
helmsman of the hardware,
shifts steer to the inway – our main
workflow.
And "Hello World!"
is shewn on the showglass!
Hello World!
Ending
Our riddlelist is now done, and steer goes back to the runwarden.
For such a groundish riddlelist, all of these works – inwoven-words, fount wordcraft and reckoner’s tongue, runwardens – might strike as overkill.
But as you learn to weave your own riddlelists with wendings most wonderful, the might of these works will be made open to sight.
Good luck!
Thankings
The writer thanks Andy Vargas for hunting down many Frankish words in the first draft of this writing.