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•9mo ago

Comments

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

Show HN: I ported Tree-sitter to Go

https://github.com/odvcencio/gotreesitter
116•odvcencio•2h ago•39 comments

Jimi Hendrix was a systems engineer

https://spectrum.ieee.org/jimi-hendrix-systems-engineer
12•tintinnabula•16m ago•2 comments

Bus stop balancing is fast, cheap, and effective

https://worksinprogress.co/issue/the-united-states-needs-fewer-bus-stops/
212•surprisetalk•4h ago•343 comments

om

https://www.om-language.com/
127•tosh•2h ago•28 comments

Large-Scale Online Deanonymization with LLMs

https://simonlermen.substack.com/p/large-scale-online-deanonymization
101•DalasNoin•1d ago•116 comments

Windows 11 Notepad to support Markdown

https://blogs.windows.com/windows-insider/2026/01/21/notepad-and-paint-updates-begin-rolling-out-...
47•andreynering•3h ago•103 comments

Following 35% growth, solar has passed hydro on US grid

https://arstechnica.com/science/2026/02/final-2025-data-is-in-us-energy-use-is-up-as-solar-passes...
243•rbanffy•3h ago•151 comments

AIs can't stop recommending nuclear strikes in war game simulations

https://www.newscientist.com/article/2516885-ais-cant-stop-recommending-nuclear-strikes-in-war-ga...
112•ceejayoz•7h ago•126 comments

The Misuses of the University

https://www.publicbooks.org/the-misuses-of-the-university/
81•ubasu•3h ago•58 comments

I asked Claude for 37,500 random names, and it can't stop saying Marcus

https://github.com/benjismith/ai-randomness
44•benjismith•4h ago•37 comments

Never buy a .online domain

https://www.0xsid.com/blog/online-tld-is-pain
577•ssiddharth•7h ago•334 comments

How to fold the Blade Runner origami unicorn (1996)

https://web.archive.org/web/20011104015933/www.linkclub.or.jp/~null/index_br.html
213•exvi•2d ago•29 comments

Trellis AI (YC W24) is hiring deployment lead to accelerate medication access

https://www.ycombinator.com/companies/trellis-ai/jobs/7ZlvQkN-lead-deployment-strategist
1•macklinkachorn•3h ago

GNU Texmacs

https://www.texmacs.org/tmweb/home/welcome.en.html
68•remywang•4h ago•25 comments

Claude Code Remote Control

https://code.claude.com/docs/en/remote-control
419•empressplay•13h ago•236 comments

New accounts on HN more likely to use em-dashes

https://www.marginalia.nu/weird-ai-crap/hn/
452•todsacerdoti•5h ago•376 comments

Show HN: Django-xbench – slow endpoint aggregation for Django

https://github.com/yeongbin05/django-xbench
6•yeongbin05•3d ago•2 comments

Attyx – tiny and fast GPU-accelerated terminal emulator written in Zig

https://github.com/semos-labs/attyx
10•nicholasrq•1h ago•7 comments

Text-Based Google Directions

https://gdir.telae.net/
33•TigerUniversity•4d ago•11 comments

Scipy.stats. Chatterjeexi

https://docs.scipy.org/doc/scipy/reference/generated/scipy.stats.chatterjeexi.html
16•kamaraju•3d ago•2 comments

Devirtualization and Static Polymorphism

https://david.alvarezrosa.com/posts/devirtualization-and-static-polymorphism/
7•dalvrosa•1h ago•0 comments

Racket v9.1

https://blog.racket-lang.org/2026/02/racket-v9-1.html
96•azhenley•3h ago•11 comments

Show HN: Django Control Room – All Your Tools Inside the Django Admin

https://github.com/yassi/dj-control-room
85•yassi_dev•6h ago•44 comments

US orders diplomats to fight data sovereignty initiatives

https://www.reuters.com/sustainability/boards-policy-regulation/us-orders-diplomats-fight-data-so...
326•colinhb•5h ago•280 comments

Danish government agency to ditch Microsoft software (2025)

https://therecord.media/denmark-digital-agency-microsoft-digital-independence
649•robtherobber•10h ago•329 comments

Topological Naming Problem

https://wiki.freecad.org/Topological_naming_problem
49•tripdout•4d ago•18 comments

PL/0

https://en.wikipedia.org/wiki/PL/0
44•tosh•3d ago•12 comments

Launch HN: TeamOut (YC W22) – AI agent for planning company retreats

https://app.teamout.com/ai
28•vincentalbouy•6h ago•35 comments

100M-Row Challenge with PHP

https://github.com/tempestphp/100-million-row-challenge
157•brentroose•10h ago•77 comments

LLM=True

https://blog.codemine.be/posts/2026/20260222-be-quiet/
194•avh3•11h ago•134 comments