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.

System76 on Age Verification Laws

https://blog.system76.com/post/system76-on-age-verification/
62•LorenDB•1h ago•20 comments

GPT-5.4

https://openai.com/index/introducing-gpt-5-4/
740•mudkipdev•11h ago•624 comments

Nobody ever got fired for using a struct

https://www.feldera.com/blog/nobody-ever-got-fired-for-using-a-struct
73•gz09•3d ago•47 comments

Where things stand with the Department of War

https://www.anthropic.com/news/where-stand-department-war
346•surprisetalk•5h ago•330 comments

10% of Firefox crashes are caused by bitflips

https://mas.to/@gabrielesvelto/116171750653898304
407•marvinborner•1d ago•217 comments

The Brand Age

https://paulgraham.com/brandage.html
297•bigwheels•12h ago•242 comments

Stop Using Grey Text (2025)

https://catskull.net/stop-using-grey-text.html
59•catskull•6h ago•36 comments

Labor market impacts of AI: A new measure and early evidence

https://www.anthropic.com/research/labor-market-impacts
122•jjwiseman•7h ago•163 comments

Show HN: Swarm – Program a colony of 200 ants using a custom assembly language

https://dev.moment.com/
20•armandhammer10•1h ago•9 comments

CBP tapped into the online advertising ecosystem to track peoples’ movements

https://www.404media.co/cbp-tapped-into-the-online-advertising-ecosystem-to-track-peoples-movements/
419•ece•1d ago•174 comments

Good software knows when to stop

https://ogirardot.writizzy.com/p/good-software-knows-when-to-stop
389•ssaboum•16h ago•202 comments

A standard protocol to handle and discard low-effort, AI-Generated pull requests

https://406.fail/
139•Muhammad523•7h ago•42 comments

Wikipedia was in read-only mode following mass admin account compromise

https://www.wikimediastatus.net
930•greyface-•13h ago•321 comments

A GitHub Issue Title Compromised 4k Developer Machines

https://grith.ai/blog/clinejection-when-your-ai-tool-installs-another
368•edf13•13h ago•91 comments

TeX Live 2026 is available for download now

https://www.tug.org/texlive/acquire.html
8•jithinraj•42m ago•2 comments

Hardware hotplug events on Linux, the gory details

https://arcanenibble.github.io/hardware-hotplug-events-on-linux-the-gory-details.html
130•todsacerdoti•3d ago•10 comments

A ternary plot of citrus geneology

https://www.jlauf.com/writing/citrus/
113•jlauf•2d ago•20 comments

Hacking Super Mario 64 using covering spaces

https://happel.ai/posts/covering-spaces-geometries-visualized/
26•nill0•3d ago•4 comments

Remotely unlocking an encrypted hard disk

https://jyn.dev/remotely-unlocking-an-encrypted-hard-disk/
112•janandonly•11h ago•58 comments

How to install and start using LineageOS on your phone

https://lockywolf.net/2026-02-19_How-to-install-and-start-using-LineageOS-on-your-phone.d/index.html
29•todsacerdoti•5h ago•12 comments

Show HN: Jido 2.0, Elixir Agent Framework

https://jido.run/blog/jido-2-0-is-here
262•mikehostetler•14h ago•57 comments

Structured AI (YC F25) Is Hiring

https://www.ycombinator.com/companies/structured-ai/jobs/3cQY6Cu-mechanical-design-engineer-found...
1•issygreenslade•9h ago

Data Does Not Speak to You

https://tantaman.com/2026-03-02-data-doesnt-speak.html
4•tantaman•2d ago•0 comments

Launch HN: Vela (YC W26) – AI for complex scheduling

42•Gobhanu•12h ago•37 comments

Show HN: PageAgent, A GUI agent that lives inside your web app

https://alibaba.github.io/page-agent/
82•simon_luv_pho•13h ago•47 comments

Judge orders government to begin refunding more than $130B in tariffs

https://www.wsj.com/politics/policy/judge-orders-government-to-begin-refunding-more-than-130-bill...
886•JumpCrisscross•15h ago•647 comments

AI and the Ship of Theseus

https://lucumr.pocoo.org/2026/3/5/theseus/
77•pixelmonkey•14h ago•85 comments

Proton Mail Helped FBI Unmask Anonymous 'Stop Cop City' Protester

https://www.404media.co/proton-mail-helped-fbi-unmask-anonymous-stop-cop-city-protestor/
301•sedatk•8h ago•146 comments

OpenTitan Shipping in Production

https://opensource.googleblog.com/2026/03/opentitan-shipping-in-production.html
97•rayhaanj•11h ago•16 comments

Breaking Down 50M Pins: A Smarter Way to Design 3D IC Packages

https://www.allaboutcircuits.com/industry-articles/breaking-down-50-million-pins-a-smarter-way-to...
3•WaitWaitWha•2h ago•0 comments