HNHacker News
TopNewBestAskShowJobs

thaliaarchi

819 karma · joined April 6, 2020

thalia.dev
submissionscomments
thaliaarchi··on Coq typeclass resolution is Turing-complete
Author here! I had a hunch that the typeclass resolution engine in the Coq typechecker could be Turing-complete, so I proved it by implementing a variant of Brainfuck in it. Feedback welcome.
thaliaarchi··on Zq: An easier and faster alternative to jq
I find the stateless streaming paradigm in jq very pleasing.

Results can be emitted iteratively using generators, which are implemented as tail-recursive streams [0]. Combined with the `input` built-in filter, which yields the next item in the input stream, and jq can handle real-time I/O and function as a more general-purpose programming language.

I built an interpreter for the Whitespace programming language in jq using these concepts and it's easily one of the most complex jq programs out there.

[0]: https://stedolan.github.io/jq/manual/#Generatorsanditerators

[1]: https://github.com/andrewarchi/wsjq

thaliaarchi··on Turing Complete is a game about computer science
Sounds like the Nand to Tetris course, gamified.

https://www.nand2tetris.org/

thaliaarchi··on An Introduction to JQ
jq is unsurprisingly Turing complete, so I wrote a Whitespace interpreter[0] in jq. It is able to handle real-time I/O by requesting lines on-demand from stdin, which is the main input source, with `input` and outputting strings in a stream.

With a relatively large jq program like that, it is critical that the main recursive loop run efficiently, so it's annoying that there's no way to detect whether tail call optimization was applied, other than benchmarking. It would also be nice if object values were lazily evaluated so that it would be possible to create ad hoc switches.

[0]: https://github.com/andrewarchi/wsjq

thaliaarchi··on The top-ranking HTML editor on Google is an SEO scam
Anecdotally DuckDuckGo seems to have fewer sponsored sites than Google. DDG also makes it easy to block low-quality sites because it adds a data-domain attribute to the root of every search result. I recently started this mini uBlock Origin filter list for that (suggestions welcome!):

    ! Hide low-quality results on DuckDuckGo
    duckduckgo.com##[data-domain="w3schools.com"]
    duckduckgo.com##[data-domain$=".w3schools.com"]
    duckduckgo.com##[data-domain="w3schools.in"]
    duckduckgo.com##[data-domain$=".w3schools.in"]
    duckduckgo.com##[data-domain="download.cnet.com"]
    !! Stack Exchange mirrors
    duckduckgo.com##[data-domain="exceptionshub.com"]
    duckduckgo.com##[data-domain="intellipaat.com"]
thaliaarchi··on Show HN: Redact – Automated deletion for your content on social networks
Is Redact affiliated with the EFF? The prominent “Support the EFF” banner suggests so, but the FAQ makes no mention.
thaliaarchi··on Fastly hires entire Wasmtime team from Mozilla
It's good to see Wasm development continuing outside of Mozilla, but it's a shame that Mozilla seems to be going under.
thaliaarchi··on This page is a truly naked, brutalist HTML quine
In a similar fashion of transforming the mechanics of code as art, this reminds me of code poetry.

Here is my favorite, Capsized by Zak Kain for Stanford's Code Poetry Slam:

    .ocean {
        color: cornflowerblue;
        pitch: high;
        overflow: visible;
    }

    .boat {
        color: firebrick;
        transform: rotate(94deg);
        float: none;
    }

    .rescue-team {
        visibility: visible;
    }

    .crew {
        widows: none;
    }
https://web.archive.org/web/20170522035639/http://stanford.e...
← PreviousPage 3 of 3