Zach Gotsch
2016-08-15 10:13:41 UTC
Hey I was looking at some of the Hoon resources this weekend and I had a
few questions and things I didn't understand. I hope this is an appropriate
place for my questions.
i)
There seems to be some sort of output formatting for floats, since
but
Where can I see how the pretty-printing in dojo is happening (if that's
even what this is...)?
ii)
I don't think I understand how constant nouns (rocks?) are represented.
%a has aura (mold? not sure of the difference here either) $a, but the raw
value 97
%97 also has raw value 97, but aura $97
I would expect =(%a %97) to be .y, since I don't expect the types to have
any bearing on equality testing. Instead it is an error. I guess my main
question here is "When do types (er, auras?) matter?" Something like (add
%97 1) doesn't cause an error, and produces 98, which I expect if add
doesn't care about types. Side note, casting the rocks seems to prevent the
%.y
iii)
From the docs: "When we print b, or any core, we see that typed noun
printing can't be an invertible function in Hoon". I don't understand why
it's not invertable. Is it because the battery is Nock, and you can't enter
nock code in Hoon?
iv)
@n seems to be a thing but I can't use it at the prompt without causing an
error. Is this like undefined/bottom in haskell?
v)
I was messing around with auras and I was wondering if `@tr`1 was something
like ~s1 (or milliseconds or microseconds). When I typed it into dojo, it
printed all sorts of stuff and overwrote the prompt. What is the stuff that
it prints and why does this happen? (After typing this out, I realized that
it's a runtime error of some kind. Where can I learn how to interpret the
printed stuff?)
vi)
In the documentation, it says ;; applies a mold, asserting fixed point. All
molds should have fixed points for all inputs because they are idempotent,
right? So is this just a function application of the mold and an assertion
that it is, in fact idempotent?
vii)
Is there a way to refer to the last twig in the dojo prompt (like `it` in
ghci)?
viii)
it(@)
~[0 1 2 3 4 5]
I don't understand the type of gulf's output, it isn't a cell, and I
haven't seen `it(@)`. Does `it` mean "iterated". Is `@` a type parameter
here?
I hope this wasn't too much for the mailing list but since the network is
down I haven't been able to bother people on :talk
Zach
few questions and things I didn't understand. I hope this is an appropriate
place for my questions.
i)
There seems to be some sort of output formatting for floats, since
(add:rs .0.1 .0.2)
.3e-1but
(add:rd .~0.1 .~0.2)
.~3.0000000000000004e-1Where can I see how the pretty-printing in dojo is happening (if that's
even what this is...)?
ii)
I don't think I understand how constant nouns (rocks?) are represented.
%a has aura (mold? not sure of the difference here either) $a, but the raw
value 97
%97 also has raw value 97, but aura $97
I would expect =(%a %97) to be .y, since I don't expect the types to have
any bearing on equality testing. Instead it is an error. I guess my main
question here is "When do types (er, auras?) matter?" Something like (add
%97 1) doesn't cause an error, and produces 98, which I expect if add
doesn't care about types. Side note, casting the rocks seems to prevent the
%.y
iii)
From the docs: "When we print b, or any core, we see that typed noun
printing can't be an invertible function in Hoon". I don't understand why
it's not invertable. Is it because the battery is Nock, and you can't enter
nock code in Hoon?
iv)
@n seems to be a thing but I can't use it at the prompt without causing an
error. Is this like undefined/bottom in haskell?
v)
I was messing around with auras and I was wondering if `@tr`1 was something
like ~s1 (or milliseconds or microseconds). When I typed it into dojo, it
printed all sorts of stuff and overwrote the prompt. What is the stuff that
it prints and why does this happen? (After typing this out, I realized that
it's a runtime error of some kind. Where can I learn how to interpret the
printed stuff?)
vi)
In the documentation, it says ;; applies a mold, asserting fixed point. All
molds should have fixed points for all inputs because they are idempotent,
right? So is this just a function application of the mold and an assertion
that it is, in fact idempotent?
vii)
Is there a way to refer to the last twig in the dojo prompt (like `it` in
ghci)?
viii)
it(@)
~[0 1 2 3 4 5]
I don't understand the type of gulf's output, it isn't a cell, and I
haven't seen `it(@)`. Does `it` mean "iterated". Is `@` a type parameter
here?
I hope this wasn't too much for the mailing list but since the network is
down I haven't been able to bother people on :talk
Zach
--
You received this message because you are subscribed to the Google Groups "urbit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to urbit-dev+***@googlegroups.com.
To post to this group, send email to urbit-***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to the Google Groups "urbit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to urbit-dev+***@googlegroups.com.
To post to this group, send email to urbit-***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.