<story><title>Sigils are underappreciated (2022)</title><url>https://raku-advent.blog/2022/12/20/sigils/</url></story><parent_chain></parent_chain><comment><author>jerf</author><text>I like to rate programming language&amp;#x27;s features not by how much I use them when I&amp;#x27;m in the given language, or how good they make me feel, but by how much I miss them when I&amp;#x27;m in a different language, once I&amp;#x27;m fluent in that language and writing in the native idiom. (This is important. If you&amp;#x27;re still trying to write X in Y, yes, you&amp;#x27;ll miss the features from X, but that&amp;#x27;s not a useful data point.)&lt;p&gt;By this metric, rather a lot of features turn out to be less important than they may seem at first. Many things are a zero on this scale that I think might surprise people still on their second or third language. From this perspective you start judging not whether a language has this or that exact feature that is a solution to a problem that you are used to, but whether it has a solution at all, and how good it is on its own terms.&lt;p&gt;So while sigils have a lot of company in this, they are also a flat zero for me on this scale. Never ever missed them. I did a decade+ of Perl as my main language, so it&amp;#x27;s not for lack of exposure.&lt;p&gt;(As an example of something that does pass this test: Closures. Hard to use anything lacking them, though as this seems to be a popular opinion nowadays, almost everything has them. But I&amp;#x27;m old enough to remember them being a controversial feature. Also, at this point, static types. Despite my decades of dynamic typed languages, I hate going back to dynamic languages anymore. YMMV.)</text></comment>
<story><title>Sigils are underappreciated (2022)</title><url>https://raku-advent.blog/2022/12/20/sigils/</url></story><parent_chain></parent_chain><comment><author>karmakaze</author><text>Perl5 got sigils wrong, where more complex usages hinted at incorrect human parsing of expressions. That was designed borrowing from natural language, so wd should probably throw out the early part of the post. Now the post says in Raku&lt;p&gt;&lt;pre&gt;&lt;code&gt;  @  says “Use me with an array-like interface”
  %  says “Use me with a hash-like interface”
  &amp;amp;  says “Use me with a function-like interface”
  $  says “I won’t tell you what interface you can use, but treat me as a single item”
&lt;/code&gt;&lt;/pre&gt;
I don&amp;#x27;t use Raku nor used much of Perl5 (only enough to learn it&amp;#x27;s good for writing, not for reading). Sigils in Raku may be fine and better than not using them. I&amp;#x27;ll accept that.&lt;p&gt;However, I much prefer inferred static typing and referential transparency where everything produces a value and it&amp;#x27;s not material whether it&amp;#x27;s a precomputed value or something that will produce the value when &amp;#x27;pulled on&amp;#x27;. The last part works well with pure functions and lazy evaluation. Until someone claiming benefits of sigils has used this alternative for large, long-lived code written and maintained by many, I&amp;#x27;ll leave sigils to Raku alone.</text></comment>