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

Removing the modem and GPS from my 2024 RAV4 hybrid

https://arkadiyt.com/2026/05/13/removing-the-modem-and-gps-from-my-rav4/
655•arkadiyt•9h ago•387 comments

A few words on DS4

https://antirez.com/news/165
182•caust1c•4h ago•57 comments

First public macOS kernel memory corruption exploit on Apple M5

https://blog.calif.io/p/first-public-kernel-memory-corruption
280•quadrige•8h ago•53 comments

RTX 5090 and M4 MacBook Air: Can It Game?

https://scottjg.com/posts/2026-05-05-egpu-mac-gaming/
500•allenleee•11h ago•139 comments

New Nginx Exploit

https://github.com/DepthFirstDisclosures/Nginx-Rift
305•hetsaraiya•9h ago•67 comments

Codex is now in the ChatGPT mobile app

https://openai.com/index/work-with-codex-from-anywhere/
203•mikeevans•6h ago•102 comments

Mullvad exit IPs are surprisingly identifying

https://tmctmt.com/posts/mullvad-exit-ips-as-a-fingerprinting-vector/
9•RGBCube•27m ago•0 comments

Tesla Wall Connector bootloader bypasses the firmware downgrade ratchet

https://www.synacktiv.com/en/publications/exploiting-the-tesla-wall-connector-from-its-charge-por...
64•p_stuart82•6h ago•26 comments

RISC-V Router

https://router.start9.com/
82•janandonly•6h ago•43 comments

7 in 10 Americans oppose data centers being built in their communities

https://www.washingtonpost.com/nation/2026/05/13/7-10-americans-oppose-data-centers-being-built-t...
40•1vuio0pswjnm7•1h ago•32 comments

UFerris a Versatile Learner Board for Rust Embedded Beginners

https://www.theembeddedrustacean.com/uferris
8•stmw•1h ago•0 comments

OVMS: Open source electric vehicle remote monitoring, diagnosis and control

https://www.openvehicles.com/home
45•BHSPitMonkey•5h ago•5 comments

Porting 3D Movie Maker to Linux

https://benstoneonline.com/posts/porting-3d-movie-maker-to-linux/
85•speckx•3d ago•13 comments

More than sixty percent of the United States is experiencing drought conditions

https://news.vt.edu/articles/2026/05/drought-united-states-la-nina-expert.html
108•littlexsparkee•4h ago•50 comments

HDD Firmware Hacking

https://icode4.coffee/?p=1465
138•jsploit•10h ago•17 comments

New arXiv policy: 1-year ban for hallucinated references

https://twitter.com/tdietterich/status/2055000956144935055
323•gjuggler•6h ago•100 comments

Velonus – Open-source AppSec scanner that deduplicates SAST noise

https://github.com/AliAmmar15/Velonus
5•AliAmmar15•2h ago•0 comments

Infracost (YC W21) Is Hiring Sr Dev Advocate to make agents cloud cost-aware

https://www.ycombinator.com/companies/infracost/jobs/NzwUQ7c-senior-developer-advocate
1•akh•6h ago

Show HN: GridTravel- A community based travel app for users to share routes

https://www.gridtravel.app
25•knuaym9•4h ago•8 comments

Ontario auditors find doctors' AI note takers routinely blow basic facts

https://www.theregister.com/ai-ml/2026/05/14/ontario-auditors-find-doctors-ai-note-takers-routine...
133•sohkamyung•4h ago•55 comments

Computer Hobby Movement in Canada

https://museum.eecs.yorku.ca/exhibits/show/hobby_canada/hobby_canada
189•rbanffy•14h ago•74 comments

What's in a GGUF, besides the weights – and what's still missing?

https://nobodywho.ooo/posts/whats-in-a-gguf/
102•bashbjorn•9h ago•42 comments

Rewrite Bun in Rust has been merged

https://github.com/oven-sh/bun/pull/30412
511•Chaoses•18h ago•600 comments

The Power of a Free Popsicle (2018)

https://www.gsb.stanford.edu/insights/power-free-popsicle
74•NaOH•8h ago•32 comments

A message from President Kornbluth about funding and the talent pipeline

https://president.mit.edu/writing-speeches/video-transcript-message-president-kornbluth-about-fun...
580•dmayo•12h ago•648 comments

Int a = 5; a = a++ + ++a; a =? (2011)

https://gynvael.coldwind.pl/?id=372
110•e-topy•2d ago•170 comments

Amazonbot is finally respecting robots.txt

https://xeiaso.net/notes/2026/amazonbot-respecting-robots-txt/
145•xena•6h ago•32 comments

DIY open-source ultrasound hardware on the rp2040/rp2350

http://un0rick.cc/pic0rick
69•kelu124•9h ago•6 comments

Fossils show millipede and centipede ancestors evolved legs underwater

https://phys.org/news/2026-05-ancient-sea-fossils-millipede-centipede.html
77•gmays•3d ago•2 comments

What could Functional Architecture mean? [video]

https://www.youtube.com/watch?v=x8jLOtZoOOU
3•surprisetalk•2d ago•0 comments