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.

Migrating to the EU

https://rz01.org/eu-migration/
207•exitnode•1h ago•119 comments

POSSE – Publish on your Own Site, Syndicate Elsewhere

https://indieweb.org/POSSE
179•tosh•3h ago•44 comments

Attractive students no longer receive better results as classes moved online

https://www.sciencedirect.com/science/article/pii/S016517652200283X
29•jdthedisciple•45m ago•3 comments

General Motors Is Assisting with the Restoration of a Rare EV1

https://evinfo.net/2026/03/general-motors-is-assisting-with-the-restoration-of-an-1996-ev1/
14•betacollector64•2d ago•1 comments

PC Gamer recommends RSS readers in a 37mb article that just keeps downloading

https://stuartbreckenridge.net/2026-03-19-pc-gamer-recommends-rss-readers-in-a-37mb-article/
656•JumpCrisscross•17h ago•310 comments

GitHub appears to be struggling with measly three nines availability

https://www.theregister.com/2026/02/10/github_outages/
67•richtr•1h ago•19 comments

Tin Can, a 'landline' for kids

https://www.businessinsider.com/tin-can-landline-kids-cellphone-cell-alternative-how-2025-9
171•tejohnso•2d ago•126 comments

The gold standard of optimization: A look under the hood of RollerCoaster Tycoon

https://larstofus.com/2026/03/22/the-gold-standard-of-optimization-a-look-under-the-hood-of-rolle...
416•mariuz•17h ago•117 comments

Can you get root with only a cigarette lighter? (2024)

https://www.da.vidbuchanan.co.uk/blog/dram-emfi.html
95•HeliumHydride•3d ago•18 comments

The future of version control

https://bramcohen.com/p/manyana
552•c17r•20h ago•304 comments

Show HN: The King Wen Permutation: [52, 10, 2]

https://gzw1987-bit.github.io/iching-math/
26•gezhengwen•3h ago•13 comments

Reports of code's death are greatly exaggerated

https://stevekrouse.com/precision
431•stevekrouse•1d ago•325 comments

Walmart: ChatGPT checkout converted 3x worse than website

https://searchengineland.com/walmart-chatgpt-checkout-converted-worse-472071
126•speckx•3d ago•94 comments

Why I love NixOS

https://www.birkey.co/2026-03-22-why-i-love-nixos.html
339•birkey•18h ago•243 comments

The way CTRL-C in Postgres CLI cancels queries is incredibly hack-y

https://neon.com/blog/ctrl-c-in-psql-gives-me-the-heebie-jeebies
82•andrenotgiant•2d ago•15 comments

Project Nomad – Knowledge That Never Goes Offline

https://www.projectnomad.us
483•jensgk•23h ago•164 comments

Dataframe 1.0.0.0

https://discourse.haskell.org/t/ann-dataframe-1-0-0-0/13834
38•internet_points•3h ago•3 comments

Jazz CRJ9 at New York on Mar 22nd 2026, collision with fire truck on runway

https://avherald.com/h?article=536bb98e
14•Shank•1h ago•5 comments

Flash-MoE: Running a 397B Parameter Model on a Laptop

https://github.com/danveloper/flash-moe
361•mft_•1d ago•116 comments

You are not your job

https://jry.io/writing/you-are-not-your-job/
220•jryio•20h ago•252 comments

GoGoGrandparent (YC S16) is hiring Back end Engineers

https://www.ycombinator.com/companies/gogograndparent/jobs/2vbzAw8-backend-engineer
1•davidchl•8h ago

GrapheneOS will remain usable by anyone without requiring personal information

https://grapheneos.social/@GrapheneOS/116261301913660830
447•nothrowaways•15h ago•133 comments

MAUI Is Coming to Linux

https://avaloniaui.net/blog/maui-avalonia-preview-1
225•DeathArrow•20h ago•136 comments

What young workers are doing to AI-proof themselves

https://www.wsj.com/economy/jobs/ai-jobs-young-people-careers-14282284
153•wallflower•17h ago•249 comments

Five years of running a systems reading group at Microsoft

https://armaansood.com/posts/systems-reading-group/
175•Foe•19h ago•51 comments

They’re vibe-coding spam now

https://tedium.co/2026/02/25/vibe-coded-email-spam/
107•raybb•14h ago•63 comments

Ordered dithering with arbitrary or irregular colour palettes (2023)

https://matejlou.blog/2023/12/06/ordered-dithering-for-arbitrary-or-irregular-palettes/
53•surprisetalk•5d ago•8 comments

The LCA problem revisited [pdf]

https://www3.cs.stonybrook.edu/~bender/talks/BenderFa00-lca-talk.pdf
9•remywang•5d ago•1 comments

Building an FPGA 3dfx Voodoo with Modern RTL Tools

https://noquiche.fyi/voodoo
203•fayalalebrun•22h ago•43 comments

LLMs predict my coffee

https://dynomight.net/coffee/
131•surprisetalk•4d ago•53 comments