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•1y ago

Comments

yxhuvud•1y ago
Eww, pretending to support utf8 matchers while not supporting them at all was not pretty to see.
gitroom•1y ago
Honestly that part bugs me, fake support is worse than no support imo
kayodelycaon•1y 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•1y 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•1y 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•12mo 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.

Humanoid Robot Actuators

https://www.firgelli.com/pages/humanoid-robot-actuators
99•ofrzeta•4h ago•20 comments

Using "underdrawings" for accurate text and numbers

https://samcollins.blog/underdrawings/
177•samcollins•2d ago•50 comments

BYOMesh – New LoRa mesh radio offers 100x the bandwidth

https://partyon.xyz/@nullagent/116499715071759135
348•nullagent•13h ago•113 comments

DeepClaude – Claude Code agent loop with DeepSeek V4 Pro

https://github.com/aattaran/deepclaude
405•alattaran•9h ago•147 comments

Midori, the first browser to offer a VPN with Mesh technology

https://astian.org/midori-en/performance-adblock-and-more-in-midori-11-7-1/
7•ponchale•59m ago•2 comments

Discovering hard disk physical geometry through microbenchmarking (2019)

https://blog.stuffedcow.net/2019/09/hard-disk-geometry-microbenchmarking/
64•TapamN•3d ago•3 comments

The 'Hidden' Costs of Great Abstractions

https://jdgr.net/the-hidden-costs-of-great-abstractions
148•jdgr•8h ago•51 comments

A desktop made for one

https://isene.org/2026/05/Audience-of-One.html
320•xngbuilds•16h ago•144 comments

A Treasure Trove of Fossils Rewrites the Story of Early Life

https://www.quantamagazine.org/a-treasure-trove-of-cambrian-fossils-rewrites-the-story-of-early-l...
19•worldvoyageur•2d ago•0 comments

Southwest Headquarters Tour

https://katherinemichel.github.io/blog/travel/southwest-headquarters-tour-2026.html
236•KatiMichel•14h ago•72 comments

OpenAI's o1 correctly diagnosed 67% of ER patients vs. 50-55% by triage doctors

https://www.theguardian.com/technology/2026/apr/30/ai-outperforms-doctors-in-harvard-trial-of-eme...
379•donsupreme•1d ago•320 comments

US–Indian space mission maps extreme subsidence in Mexico City

https://phys.org/news/2026-04-usindian-space-mission-extreme-subsidence.html
146•leopoldj•2d ago•59 comments

K3sup – bootstrap K3s over SSH in < 60s

https://github.com/alexellis/k3sup
46•rickcarlino•2d ago•13 comments

Tar Files Created on macOS Display Errors When Extracting on Linux (2024)

https://aruljohn.com/blog/macos-created-tar-files-linux-errors/
92•heresie-dabord•3d ago•64 comments

Denuvo has been cracked in all single-player games it previously protected

https://www.tomshardware.com/video-games/pc-gaming/denuvo-has-been-bypassed-in-all-single-player-...
317•oceansky•5d ago•191 comments

Introduction to Atom

https://validator.w3.org/feed/docs/atom.html
86•susam•9h ago•27 comments

Bad Connection: Global telecom exploitation by covert surveillance actors

https://citizenlab.ca/research/uncovering-global-telecom-exploitation-by-covert-surveillance-actors/
141•miohtama•15h ago•9 comments

New statue in London, attributed to Banksy, of a suited man, blinded by a flag

https://www.smithsonianmag.com/smart-news/attributed-to-banksy-a-new-statue-of-a-suited-man-blind...
367•dryadin•12h ago•323 comments

Mercedes-Benz commits to bringing back physical buttons

https://www.drive.com.au/news/mercedes-benz-commits-to-bringing-back-phycial-buttons/
680•teleforce•17h ago•382 comments

Stitch Together Lots of Little HTML Pages with Navigations for Interactions

https://blog.jim-nielsen.com/2026/small-html-pages/
27•OuterVale•3h ago•18 comments

Texico: Learn the principles of programming without even touching a computer

https://www3.nhk.or.jp/nhkworld/en/shows/texico/
6•o4c•2d ago•0 comments

Fun with polynomials and linear algebra; or, slight abstract nonsense

https://guille.site/posts/abstract-nonsense/
8•LolWolf•2d ago•0 comments

The text mode lie: why modern TUIs are a nightmare for accessibility

https://xogium.me/the-text-mode-lie-why-modern-tuis-are-a-nightmare-for-accessibility
196•SpyCoder77•7h ago•82 comments

Show HN: Ableton Live MCP

https://github.com/bschoepke/ableton-live-mcp
80•bschoepke•13h ago•52 comments

Text-to-CAD

https://github.com/earthtojake/text-to-cad
109•softservo•3d ago•30 comments

Why TUIs are back

https://wiki.alcidesfonseca.com/blog/why-tuis-are-back/
319•rickcarlino•13h ago•333 comments

I recreated the Apple Lisa computer inside an FPGA [video]

https://www.youtube.com/watch?v=8jNQDcpHc68
98•cyrc•14h ago•23 comments

Roger Sweet, Creator of the He-Man Action Figure, Dies at 91

https://www.nytimes.com/2026/04/29/arts/roger-sweet-dead-he-man.html
41•ChrisArchitect•2d ago•8 comments

Security through obscurity is not bad

https://mobeigi.com/blog/security/security-through-obscurity-is-not-bad/
152•mobeigi•17h ago•165 comments

Let's Buy Spirit Air

https://letsbuyspiritair.com/
310•bjhess•8h ago•300 comments