(no title)
yarvin9 | 9 years ago
And if you saw a file of Hoon molds, in normal programmer English, you'd say, "these are type declarations." I might even say it myself.
As for the external representation -- it's a name for a file containing a Hoon mold. Actually orthogonal to serialization format, as all nouns are serialized the same way. It really is more like a MIME type, if a MIME type was a function you could run. There's no word for this.
There is a common programming term for a set of values. The word is "type." "Domain" is a little bit odd, because we usually compute the "type" (span) as the range of an expression...
Bottom line is, this stuff is hard!
kazinator|9 years ago
Constructor was used (long) before C++! For instance, the "cons" function in Lisp stands for "construct", and speaking of which, ANSI Lisp even has "boa constructors" (by order of arguments). We are used to having terms like "constructor", "array" or "variable" have different shades in different languages. If I reach for Awk to munge some text fields, I'm not suddenly confused because its "arrays" are not like C arrays or Fortran arrays.
The same terms being used is actually helpful, because the terms form the pivots in conceptual mappings between languages, and comparisons. Even if two languages have different notions of what is a "variable", they are used in similar ways. It's easier to hang different shades of meaning on the same word than to memorize some made up new word. Even something quite different, like placeholders in pattern matching or predicate logic, can still be called "variable" without causing confusion.
Think about parameters/arguments. They can be by value, by name, by reference, or normal order (lazy). Using a different word instead of "parameter" for all these would be counterproductive, and make it harder to speak comparatively.
Bottom line, people aren't complete idiots.
"The Flunk language has flurbles, which are like C++ variables, but not exactly, so we use a different word. Unlike variables denote locations which do not have a type and can store any value." (Gee, that's just like "variables" in some existing languages that are not C++.)
kazinator|9 years ago
yarvin9|9 years ago
But maybe it's worth it to stop the middlebrow dismissals! Our grandparents went to the moon. We complain when we have to learn a slightly new idea, and faint like Victorians contemplating legs if it has a new name.
"Argument" is another good one. Hoon is a single-argument language that favors tuples, not currying. So an add function, (add a b), is actually (add [a b]), or in Lisp (add (cons a b)).
In Hoon, you can call a and b "arguments" all day long. It's an informal word. But [a b] is "the sample." You can see the chaos that would result if we called it "the argument" or "the parameter"...