frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Fast(er) regular expression engines in Ruby

https://serpapi.com/blog/faster-regular-expression-engines-in-ruby/
60•davidsojevic•10mo ago

Comments

yxhuvud•10mo ago
Eww, pretending to support utf8 matchers while not supporting them at all was not pretty to see.
gitroom•10mo ago
Honestly that part bugs me, fake support is worse than no support imo
kayodelycaon•10mo ago
> Another nuance was found in ruby, which cannot scan the haystack with invalid UTF-8 byte sequences.

This is extremely basic ruby: UTF-8 encoded strings must be valid UTF-8. This is not unique to ruby. If I recall correctly, python 3 does the same thing.

    2.7.1 :001 > haystack = "\xfc\xa1\xa1\xa1\xa1\xa1abc"
    2.7.1 :003 > haystack.force_encoding "ASCII-8BIT"
    => "\xFC\xA1\xA1\xA1\xA1\xA1abc" 
    2.7.1 :004 > haystack.scan(/.+/)
    => ["\xFC\xA1\xA1\xA1\xA1\xA1abc"]
This person is a senior engineer on their Team page. All they had to do was google "ArgumentError: invalid byte sequence in UTF-8". Or ask a coworker... the company has Ruby on Rails applications. headdesk
burntsushi•10mo ago
The nuance is specifically relevant here because neither of the other two regex engines benchmarked have this requirement. It's doubly relevant because that means running a regex search doesn't require a UTF-8 validation step, and is therefore likely beneficial from a perf perspective, dependening on the workload.
kayodelycaon•10mo ago
That’s a good point. I hadn’t considered it because I’ve hit the validation error long before getting to search. It is possible to avoid string operations with careful coding prior to the search.

Edit: After a little testing, the strings can be read from and written to files without triggering validation. Presumably this applies to sockets as well.

DmitryOlshansky•10mo ago
I wonder how std.regex of dlang would fare in such test. Sadly due to a tiny bit of D’s GC use it’s hard to provide as a library for other languages. If there is an interest I might take it through the tests.

I put my whole life into a single database

https://howisfelix.today/
111•lukakopajtic•2h ago•28 comments

Redox OS has adopted a Certificate of Origin policy and a strict no-LLM policy

https://gitlab.redox-os.org/redox-os/redox/-/blob/master/CONTRIBUTING.md
204•pjmlp•3h ago•171 comments

The Gervais Principle, or the Office According to "The Office" (2009)

https://www.ribbonfarm.com/2009/10/07/the-gervais-principle-or-the-office-according-to-the-office/
93•janandonly•3d ago•23 comments

Ask HN: Remember Fidonet?

35•ukkare•1h ago•14 comments

FreeBSD 14.4-Release Announcement

https://www.freebsd.org/releases/14.4R/announce/
14•vermaden•1h ago•1 comments

Two Years of Emacs Solo

https://www.rahuljuliato.com/posts/emacs-solo-two-years
282•celadevra_•12h ago•90 comments

Lotus 1-2-3 on the PC with DOS

https://stonetools.ghost.io/lotus123-dos/
121•TMWNN•3d ago•41 comments

LoGeR – 3D reconstruction from extremely long videos (DeepMind, UC Berkeley)

https://loger-project.github.io
76•helloplanets•6h ago•20 comments

TCXO Failure Analysis

https://serd.es/2026/03/06/TCXO-failure-analysis.html
40•zdw•3d ago•9 comments

Practical Guide to Bare Metal C++

https://arobenko.github.io/bare_metal_cpp/#_abstract_classes
18•ibobev•3d ago•2 comments

Building a Procedural Hex Map with Wave Function Collapse

https://felixturner.github.io/hex-map-wfc/article/
525•imadr•19h ago•72 comments

The hidden compile-time cost of C++26 reflection

https://vittorioromeo.com/index/blog/refl_compiletime.html
41•SuperV1234•3d ago•17 comments

Optimizing Top K in Postgres

https://www.paradedb.com/blog/optimizing-top-k
100•philippemnoel•1d ago•12 comments

Is legal the same as legitimate: AI reimplementation and the erosion of copyleft

https://writings.hongminhee.org/2026/03/legal-vs-legitimate/
497•dahlia•21h ago•514 comments

JSLinux Now Supports x86_64

https://bellard.org/jslinux/
340•TechTechTech•19h ago•108 comments

No, it doesn't cost Anthropic $5k per Claude Code user

https://martinalderson.com/posts/no-it-doesnt-cost-anthropic-5k-per-claude-code-user/
282•jnord•13h ago•203 comments

Show HN: Remotely use my guitar tuner

https://realtuner.online/
219•smith-kyle•3d ago•48 comments

Show HN: I Was Here – Draw on street view, others can find your drawings

https://washere.live
42•mrktsm__•7h ago•28 comments

Yann LeCun's AI startup raises $1B in Europe's largest ever seed round

https://www.ft.com/content/e5245ec3-1a58-4eff-ab58-480b6259aaf1
96•ottomengis•1h ago•76 comments

macOS Tahoe windows have different corner radiuses

https://lapcatsoftware.com/articles/2026/3/1.html
209•robenkleene•3d ago•154 comments

Darkrealms BBS

http://www.darkrealms.ca/
113•TigerUniversity•3d ago•30 comments

Learnings from paying artists royalties for AI-generated art

https://www.kapwing.com/blog/learnings-from-paying-artists-royalties-for-ai-generated-art/
148•jenthoven•10h ago•118 comments

The “JVG algorithm” only wins on tiny numbers

https://scottaaronson.blog/?p=9615
73•jhalderm•12h ago•40 comments

Graphing how the 10k* most common English words define each other

https://wyattsell.com/experiments/word-graph/
84•wyattsell•2d ago•20 comments

Show HN: DenchClaw – Local CRM on Top of OpenClaw

https://github.com/DenchHQ/DenchClaw
127•kumar_abhirup•21h ago•106 comments

EVi, a Hard-Fork of Vim

https://codeberg.org/NerdNextDoor/evi
13•todsacerdoti•2h ago•6 comments

DARPA’s new X-76

https://www.darpa.mil/news/2026/darpa-new-x-76-speed-of-jet-freedom-of-helicopter
207•newer_vienna•19h ago•194 comments

Launch HN: Terminal Use (YC W26) – Vercel for filesystem-based agents

107•filipbalucha•19h ago•76 comments

An opinionated take on how to do important research that matters

https://nicholas.carlini.com/writing/2026/how-to-win-a-best-paper-award.html
140•mad•20h ago•35 comments

Getting Started in Common Lisp

https://lisp-stat.dev/blog/2026/03/09/getting-started/
58•oumua_don17•12h ago•16 comments