Re:STON – Smalltalk Object Notation (2012)
by rurban on Wednesday March 15, 2017 @10:20AM
(#13876262)
I was referring to the # pound syntax for fields.
fields can be used with a . or - prefix much more pleasingly to the eyes. An untrained eye would take the # for comments.
[ Parent
| on HN ]
Re:STON – Smalltalk Object Notation (2012)
by s-phi-nl on Wednesday March 15, 2017 @11:19AM
(#13876689)
Your untrained eye took the # for comments, but I'm not sure that generalized to anyone's. Plenty of languages use # for other things: Smalltalk uses them for symbols, Clojure uses them for reader macros, OCaml uses them for method calls, Haskell can use them as an arbitrary operator, Lua uses them for length, C and C++ use them for compiler directives. See https://en.wikipedia.org/wiki/Number_sign#In_computing for a list.
Admittedly, Python, Bash, Perl, and Ruby use # for comments, so you do have a point, especially since Python is such a common teaching language.
Re:STON – Smalltalk Object Notation (2012)
by rurban on Wednesday March 15, 2017 @12:12PM
(#13877129)
No, the point is the clutter.
A pound # is the most intrusive ascii character, with about 85% black. Older languages were critised to use $ with about 55% black as prefix. It's like writing in ALL-CAPS.
This is a very valid critique in terms of graphic design.
(For anyone confused by the mention of graphic design: it's all about communicating information through visuals.)
Re:STON – Smalltalk Object Notation (2012)
by optimuspaul on Wednesday March 15, 2017 @01:05PM
(#13877700)
Oh, I thought they were hashtags, I was gonna see if they were trending on twitter.
Re:STON – Smalltalk Object Notation (2012)
by yellowapple on Wednesday March 15, 2017 @08:55PM
(#13881421)
"An untrained eye would take the # for comments"
\begin{pedantry}
I'd argue that an untrained eye would take the # for ordinary syntax noise, since such an eye would have no notion of a "comment". A trained eye might be confused by that, but only if it was trained against an environment that uses # for comments.
\end{pedantry}