<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Hacker News: duckerude</title><link>https://news.ycombinator.com/user?id=duckerude</link><description>Hacker News RSS</description><docs>https://hnrss.org/</docs><generator>hnrss v2.1.1</generator><lastBuildDate>Sun, 03 May 2026 09:42:42 +0000</lastBuildDate><atom:link href="https://hnrss.org/user?id=duckerude" rel="self" type="application/rss+xml"></atom:link><item><title><![CDATA[New comment by duckerude in "No right to relicense this project"]]></title><description><![CDATA[
<p>Perhaps notable: years ago the <i>original</i> original chardet was rewritten with a different license: <a href="https://github.com/hsivonen/chardetng" rel="nofollow">https://github.com/hsivonen/chardetng</a><p>AFAIK this was not a clean room reimplementation. But since it was rewritten by hand, into a different language, with not just a different internal design but a different API, I could easily buy that chardetng doesn't infringe while Python chardet 7 does.</p>
]]></description><pubDate>Thu, 05 Mar 2026 12:31:50 +0000</pubDate><link>https://news.ycombinator.com/item?id=47260871</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=47260871</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=47260871</guid></item><item><title><![CDATA[New comment by duckerude in "Motorola announces a partnership with GrapheneOS"]]></title><description><![CDATA[
<p>Previously: <a href="https://news.ycombinator.com/item?id=45585869">https://news.ycombinator.com/item?id=45585869</a><p>(At the time it wasn't public which OEM GrapheneOS would partner with.)</p>
]]></description><pubDate>Mon, 02 Mar 2026 07:18:34 +0000</pubDate><link>https://news.ycombinator.com/item?id=47214789</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=47214789</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=47214789</guid></item><item><title><![CDATA[New comment by duckerude in "Notes on Clarifying Man Pages"]]></title><description><![CDATA[
<p>Looks like the command is still called tldr at least, only the package/repo has a different name.</p>
]]></description><pubDate>Fri, 20 Feb 2026 12:55:53 +0000</pubDate><link>https://news.ycombinator.com/item?id=47087423</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=47087423</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=47087423</guid></item><item><title><![CDATA[New comment by duckerude in "Defer available in gcc and clang"]]></title><description><![CDATA[
<p>That comment is saying to use C++, not to add destructors to C.</p>
]]></description><pubDate>Fri, 20 Feb 2026 07:28:14 +0000</pubDate><link>https://news.ycombinator.com/item?id=47084829</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=47084829</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=47084829</guid></item><item><title><![CDATA[Multo ante natus eram (1995)]]></title><description><![CDATA[
<p>Article URL: <a href="https://multicians.org/multo-antes.html">https://multicians.org/multo-antes.html</a></p>
<p>Comments URL: <a href="https://news.ycombinator.com/item?id=46744642">https://news.ycombinator.com/item?id=46744642</a></p>
<p>Points: 2</p>
<p># Comments: 0</p>
]]></description><pubDate>Sat, 24 Jan 2026 15:57:16 +0000</pubDate><link>https://multicians.org/multo-antes.html</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=46744642</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=46744642</guid></item><item><title><![CDATA[New comment by duckerude in "Avoid UUID Version 4 Primary Keys in Postgres"]]></title><description><![CDATA[
<p>I've worked on a system where ULIDs (not UUIDv7, but similar) were used with a cursor to fetch data in chronological order and then—surprise!—one day records had to be backdated, meaning that either the IDs for those records had to be counterfeited (potentially violating invariants elsewhere) or the fetching had to be made smarter.<p>You can choose to never make use of that property. But it's tempting.</p>
]]></description><pubDate>Mon, 15 Dec 2025 17:20:42 +0000</pubDate><link>https://news.ycombinator.com/item?id=46277369</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=46277369</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=46277369</guid></item><item><title><![CDATA[New comment by duckerude in "PHP 8.5"]]></title><description><![CDATA[
<p>The current amount of typechecking might be a net efficiency improvement AFAIK. It provides a hard runtime guarantee that variables are certain types while Python has to check whether something is supported at the last possible moment. But I don't know how much use the optimizer makes of that.</p>
]]></description><pubDate>Thu, 20 Nov 2025 16:16:50 +0000</pubDate><link>https://news.ycombinator.com/item?id=45994268</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=45994268</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=45994268</guid></item><item><title><![CDATA[New comment by duckerude in "PHP 8.5"]]></title><description><![CDATA[
<p>Python managed to do this by not actually checking the types at runtime. If you declare a list[int] return type but you return a list[string] then nothing happens, you're expected to prevent that by running an offline typechecker.<p>PHP chose to check types at runtime. To check that a value is really an array<int> the runtime could have to loop through the entire array. All the types PHP currently implements are simple and cheap to check. For more elaborate cases you need an offline checker like PHPstan and comment-based type annotations. (PHPstan catches 99% of issues before the runtime gets to it so for my own code I'd prefer the Python approach with its cleaner syntax.)<p>The runtime checking seems the key difference, not so much the historical strength of the type system. Python's language implementation does very little typechecking itself and PHP's third-party offline typecheckers are respectably advanced.</p>
]]></description><pubDate>Thu, 20 Nov 2025 14:38:28 +0000</pubDate><link>https://news.ycombinator.com/item?id=45992994</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=45992994</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=45992994</guid></item><item><title><![CDATA[New comment by duckerude in "The reason GCC is not a library (2000)"]]></title><description><![CDATA[
<p>I don't think this shows deep thought on his part.<p>By Stallman's own telling a free Objective-C frontend was an unexpected outcome. Until it came up in practice he thought a proprietary compiler frontend would be legal (<a href="https://gitlab.com/gnu-clisp/clisp/blob/dd313099db351c90431c1c90332192edce2bb5c9/doc/Why-CLISP-is-under-GPL#L366" rel="nofollow">https://gitlab.com/gnu-clisp/clisp/blob/dd313099db351c90431c...</a>). So his stance in this email is a reaction to specific incidents, not careful forethought.<p>And the harms of permissive licensing for compiler frontends seem pretty underwhelming. After Apple moved to LLVM it largely kept releasing free compiler frontends. (But maybe I'd think differently if I e.g. understood GNAT's licensing better.)</p>
]]></description><pubDate>Sun, 19 Oct 2025 11:54:25 +0000</pubDate><link>https://news.ycombinator.com/item?id=45633559</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=45633559</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=45633559</guid></item><item><title><![CDATA[New comment by duckerude in "Python's splitlines does more than just newlines"]]></title><description><![CDATA[
<p>I think you're getting fooled:<p><pre><code>  >>> from io import StringIO
  >>> for line in StringIO("foo\x85bar\vquux\u2028zoot"): print(repr(line))
  ... 
  'foo\x85bar\x0bquux\u2028zoot'</code></pre></p>
]]></description><pubDate>Wed, 15 Oct 2025 11:22:48 +0000</pubDate><link>https://news.ycombinator.com/item?id=45590771</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=45590771</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=45590771</guid></item><item><title><![CDATA[New comment by duckerude in "Git: Introduce Rust and announce it will become mandatory in the build system"]]></title><description><![CDATA[
<p>rustc is only loosely tied to LLVM. Other code generation backends exist in various states of production-readiness. There are also two other compilers, mrustc and GCC-rs.<p>mrustc is a bootstrap Rust compiler that doesn't implement a borrow checker but can compile valid programs, so it's similar to to your proposed subset. Rust minus verification is still a very large and complex language though, just like C++ is large and complex.<p>A core language that's as simple to implement as C would have to be very different and many people (I suspect most) would like it less than the Rust that exists.</p>
]]></description><pubDate>Sat, 20 Sep 2025 17:56:57 +0000</pubDate><link>https://news.ycombinator.com/item?id=45315623</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=45315623</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=45315623</guid></item><item><title><![CDATA[New comment by duckerude in "RFC 9839 and Bad Unicode"]]></title><description><![CDATA[
<p>RFC 3629 says surrogate codepoints are not valid in UTF-8. So if you're decoding/validating UTF-8 it's just another kind of invalid byte sequence like a 0xFF byte or an overlong encoding. AFAIK implementations tend to follow this. (You have to make a choice but you'd have to make that choice regardless for the other kinds of error.)<p>If you run into this when encoding to UTF-8 then your source data isn't valid Unicode and it depends on what it really is if not proper Unicode. If you can validate at other boundaries then you won't have to deal with it there.</p>
]]></description><pubDate>Sat, 23 Aug 2025 19:37:53 +0000</pubDate><link>https://news.ycombinator.com/item?id=44998532</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=44998532</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=44998532</guid></item><item><title><![CDATA[New comment by duckerude in "Go is still not good"]]></title><description><![CDATA[
<p>The big problem isn't invalid UTF-8 but invalid UTF-16 (on Windows et al). AIUI Go had nasty bugs around this (<a href="https://github.com/golang/go/issues/59971" rel="nofollow">https://github.com/golang/go/issues/59971</a>) until it recently adopted WTF-8, an encoding that was actually invented for Rust's OsStr.<p>WTF-8 has some inconvenient properties. Concatenating two strings requires special handling. Rust's opaque types can patch over this but I bet Go's WTF-8 handling exposes some unintuitive behavior.<p>There is a desire to add a normal string API to OsStr but the details aren't settled. For example: should it be possible to split an OsStr on an OsStr needle? This can be implemented but it'd require switching to OMG-WTF-8 (<a href="https://rust-lang.github.io/rfcs/2295-os-str-pattern.html" rel="nofollow">https://rust-lang.github.io/rfcs/2295-os-str-pattern.html</a>), an encoding with even more special cases. (I've thrown my own hat into this ring with OsStr::slice_encoded_bytes().)<p>The current state is pretty sad yeah. If you're OK with losing portability you can use the OsStrExt extension traits.</p>
]]></description><pubDate>Fri, 22 Aug 2025 15:49:53 +0000</pubDate><link>https://news.ycombinator.com/item?id=44986043</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=44986043</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=44986043</guid></item><item><title><![CDATA[New comment by duckerude in "Writing simple tab-completions for Bash and Zsh"]]></title><description><![CDATA[
<p>Rust has the clap_complete package for its most popular arg parsing library: <a href="https://crates.io/crates/clap_complete" rel="nofollow">https://crates.io/crates/clap_complete</a><p>ripgrep exposes its (bespoke) shell completion and man page generation through a --generate option: rg --generate=man, rg --generate=complete-bash, etcetera. In xh (clap-based) we provide the same but AFAIK we're the only one to copy that interface.<p>Symfony (for PHP) provides some kind of runtime completion generation but I don't know the details.</p>
]]></description><pubDate>Sun, 10 Aug 2025 15:08:13 +0000</pubDate><link>https://news.ycombinator.com/item?id=44855703</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=44855703</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=44855703</guid></item><item><title><![CDATA[New comment by duckerude in "In POSIX, you can theoretically use inode zero"]]></title><description><![CDATA[
<p>See also: <a href="https://internals.rust-lang.org/t/can-the-standard-library-shrink-option-file/12768" rel="nofollow">https://internals.rust-lang.org/t/can-the-standard-library-s...</a><p>A file descriptor can't be -1 but it's not 100% clear whether POSIX bans other negative numbers. So Rust's stdlib only bans -1 (for a space optimization) while still allowing for e.g. -2.</p>
]]></description><pubDate>Mon, 02 Jun 2025 13:02:05 +0000</pubDate><link>https://news.ycombinator.com/item?id=44158390</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=44158390</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=44158390</guid></item><item><title><![CDATA[New comment by duckerude in "A surprising enum size optimization in the Rust compiler"]]></title><description><![CDATA[
<p>It means that anything strange that happens next isn't a language bug.<p>Whether something is a bug or not is sometimes hard to pin down because there's no formal spec. Most of the time it's pretty clear though. Most software doesn't have a formal spec and manages to categorize bugs anyway.</p>
]]></description><pubDate>Thu, 10 Apr 2025 20:31:11 +0000</pubDate><link>https://news.ycombinator.com/item?id=43647769</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=43647769</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43647769</guid></item><item><title><![CDATA[New comment by duckerude in "argp: GNU-style command line argument parser for Go"]]></title><description><![CDATA[
<p>I can think of a lot of cases where it theoretically <i>could</i> be a problem, but `cut -d=` is the only one I've found so far where an end user ran into trouble because of this ambiguity, and I think it's the only one for which uutils bothers implementing a workaround. That's why I give it special attention.<p>> You write a bit as if we disagree, but I don't see any real point of contention. :-)<p>The `cut -d:=` spelling solves a different problem than the one I meant (and the one you're now talking about). But we're mostly on the same page!</p>
]]></description><pubDate>Sun, 23 Mar 2025 20:37:28 +0000</pubDate><link>https://news.ycombinator.com/item?id=43455702</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=43455702</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43455702</guid></item><item><title><![CDATA[New comment by duckerude in "argp: GNU-style command line argument parser for Go"]]></title><description><![CDATA[
<p>The problem is existing shell scripts and muscle memory and command histories. `cut -d=` has always worked and works on all the other implementations so it should keep working if you switch to uutils.</p>
]]></description><pubDate>Sun, 23 Mar 2025 16:46:06 +0000</pubDate><link>https://news.ycombinator.com/item?id=43454057</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=43454057</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43454057</guid></item><item><title><![CDATA[New comment by duckerude in "argp: GNU-style command line argument parser for Go"]]></title><description><![CDATA[
<p>I researched this for my own argument parser (<a href="https://github.com/blyxxyz/lexopt/issues/13" rel="nofollow">https://github.com/blyxxyz/lexopt/issues/13</a>) and concluded that it's a minor issue.<p>This syntax is supported by argparse and clap, the most popular argument parsers for Python and Rust respectively, and it seems to have caused almost no problems for them. It's a problem for the uutils implementation of cut, since `cut -d=` is common, but that's the only instance I could find after a long time scouring search engines and bug trackers and asking for examples.<p>If anyone does know of other examples or other places this has been discussed I'd love to hear it though, maybe I just haven't found them.<p>(Also, the more reliable way to write this in general is `-a "$USER_CONTROLLED_DATA"`, since that'll behave correctly if $USER_CONTROLLED_DATA is empty. As will `-a="$USER_CONTROLLED_DATA"` if you know the command supports it.)</p>
]]></description><pubDate>Sun, 23 Mar 2025 15:44:36 +0000</pubDate><link>https://news.ycombinator.com/item?id=43453677</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=43453677</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43453677</guid></item><item><title><![CDATA[New comment by duckerude in "A 10x Faster TypeScript"]]></title><description><![CDATA[
<p>Anders Hejlsberg explains here: <a href="https://youtu.be/10qowKUW82U?t=1154" rel="nofollow">https://youtu.be/10qowKUW82U?t=1154</a>. TL;DW:<p>- C# is bytecode-first, Go targets native code. While C# does have AOT capabilities nowadays this is not as mature as Go's and not all platforms support it. Go also has somewhat better control over data layout. They wanted to get as low-level as possible while still having garbage collection.<p>- This is meant to be something of a 1:1 port rather than a rewrite, and the old code uses plain functions and data structures without an OOP style. This suits Go well while a C# port would have required more restructuring.</p>
]]></description><pubDate>Tue, 11 Mar 2025 15:34:52 +0000</pubDate><link>https://news.ycombinator.com/item?id=43333501</link><dc:creator>duckerude</dc:creator><comments>https://news.ycombinator.com/item?id=43333501</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43333501</guid></item></channel></rss>