frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Would you believe try-catch-finally works in plain old C?

4•mf_taria•1y ago
I was digging through some of my old repositories and found a C language extension I wrote years ago. Even now, I think it’s kinda cool — and I’d love for you to check it out.

https://github.com/simpart/c-try

It recreates `try {}` / `catch {}` / `finally {}` in plain C using just macros and global variables. There's also a `$` macro to propagate errors between function calls — a bit like a mini DSL for error handling.

You can find a working example in `test.c`.

It doesn't support nesting or multithreading, and yes, it abuses macros. But hey, it's C.

Comments

actionfromafar•1y ago
Finally!

I threat-modelled my Hyprland setup

https://demiguru.codeberg.page/wayland-compositor-threat-model/
1•DemiGuru•44s ago•0 comments

ClangIR and the Cost of MLIR

https://maskray.me/blog/clangir-and-the-cost-of-mlir
1•csmantle•53s ago•0 comments

Frances E. Dec: Mad Deadly Worldwide Communist Gangster Computer God

https://medium.com/@Goosenpai/the-curious-rants-of-francis-e-dec-esq-a164ab2ae8f
1•vegnus•1m ago•0 comments

Hosting an 'Internet Search Party'

https://lowpolybrainblasts.pika.page/posts/hosting-an-internet-search-party
1•rdmuser•2m ago•0 comments

Show HN: Marcus – catches the fake source links AI search engines invent

https://marcus-ai.dev/on-the-record/
1•lwgray•2m ago•0 comments

Bonanza of new dates rewrites the history of the Inca

https://www.science.org/content/article/bonanza-new-dates-rewrites-history-inca
1•pseudolus•4m ago•0 comments

Invalid by Design: What the Softaculous BGP Hijack Proves About RPKI

https://cloudpunk.blog/post/bgp-hijack-rpki-gap/
1•mritzmann•6m ago•0 comments

The Good Thing About Hard Things

https://calnewport.com/the-good-thing-about-hard-things/
1•samizdis•8m ago•0 comments

Neo-Technocracy: Same Dream, Bigger Budget

https://www.lwilko.com/blog/neo-technocracy-same-dream-bigger-budget
2•metafeather•9m ago•1 comments

Harness Engineering 101: The LLM is the brain, the harness is the body

https://github.com/IsuruMaduranga/harness-engineering-101
2•isuruwijesiri•10m ago•0 comments

What to Know About the Obscure Trust Looming over Anthropic's IPO

https://www.wsj.com/tech/ai/anthropic-ipo-private-trust-188f41f7
2•1vuio0pswjnm7•12m ago•2 comments

Show HN: A biotech catalyst calendar that links every date to the SEC sentence

https://www.orionbiotechai.com/
3•orionbiotech•12m ago•0 comments

Attach open data like a database: Iceberg tables over a CDN

https://lakehousebox.com/blog/public-iceberg-from-a-cdn/
1•jatorre•12m ago•0 comments

I Made a Classic GameHub

https://play.google.com/store/apps/details?id=com.playhub.spelbazi&hl=en_US
2•testbonsai•13m ago•0 comments

One Page Design Philosophy for Game Developers [video]

https://www.youtube.com/watch?v=E9_wLks1kAg
1•surprisetalk•18m ago•0 comments

Introducing The Anthropic Cyber Mission

https://www.anthropic.com/news/anthropic-cyber-mission
2•gmays•20m ago•0 comments

Marmalade TTS

https://github.com/maxwhipw/marmalade-tts-android
1•mkesper•20m ago•0 comments

Show HN: Kernwise – Kerning Game for Designers

https://www.designinspiration.info/kernwise-a-free-kerning-game-for-designers/
1•bepero•22m ago•0 comments

The Developer Communication Handbook

https://w.pitula.me/developer-communication-handbook/
1•krever•22m ago•2 comments

Self Improvement Harness based on pi. pi-harness-rsi

https://github.com/grigio/pi-harness-rsi
1•grigio•23m ago•0 comments

Did Karl Marx Predict Artificial Intelligence 170 Years Ago?

https://medium.com/@MichaelMcBride/did-karl-marx-predict-artificial-intelligence-170-years-ago-4f...
4•vrganj•24m ago•0 comments

Dockit – an open-source desktop app for container management

https://github.com/Amanbig/dockit/releases
2•procoder588•25m ago•0 comments

I Automated Website Development

https://sitesmith.t3ratech.co.zw/
2•tkaviya•29m ago•0 comments

AI native Requirements, design and simulations

https://www.meltred.com/
2•kunalsin9h•32m ago•0 comments

Dropstone composed and mixed a full orchestra in 7.1 surround for under $1

https://www.dropstone.io/blog/dropstone-nocturne-7-1-orchestra
5•DarenWatson•34m ago•0 comments

The Lucrative World of Literary Scams

https://www.thedial.world/articles/news/ai-book-scams
2•samclemens•34m ago•0 comments

The Many Failures of Larry David

https://colossus.com/article/many-failures-larry-david-profile/
3•jger15•35m ago•0 comments

Notepad++ for macOS – Native Qt 6 / Scintilla port with top plugins

https://github.com/kalderonski73/notepad-plus-plus-macos
3•k1000o73•35m ago•0 comments

DHS Political Appointees Ask CISA to Secretly Obtain Voting Machine And Hack it

https://www.propublica.org/article/cisa-election-security-donald-trump
3•DeepLogin•36m ago•0 comments

What Is Vinix? The V-Language OS That Runs Docker

https://www.fosslinux.com/162837/what-is-vinix.htm
1•baranul•43m ago•0 comments