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!

A Nation of Immigrants

https://www.witoldrybczynski.com/architects/a-nation-of-immigrants/
1•speckx•1m ago•0 comments

Don't Watch BBC, the GOV Don't Care You'll Still Pay from 2028 [video]

https://www.youtube.com/watch?v=JsBdd4PuTX4
1•dp-hackernews•1m ago•0 comments

AWS Lambda Adds GPU Instances for Event Functions on Lambda Managed Instances

https://aws.amazon.com/blogs/aws/aws-lambda-now-supports-gpu-instances-for-event-functions-on-lam...
1•ducviet00•6m ago•0 comments

In the Wilderness

https://rodrigoalvesvieira.com/2026/11/20/in-the-wilderness
1•ravieira•6m ago•0 comments

Butler Agents and Gardener Agents

https://nicholascharriere.com/blog/butlers-and-gardeners/
1•nichochar•7m ago•0 comments

Show HN: A Native GTK4/Libadwaita PDF Editor for Linux (AcroForms, PAdES, OCR)

https://github.com/word-sys/word-sys-pdf-editor
1•word-sys•8m ago•0 comments

Show HN: TripleClick – 220-line Mac menu bar app for trackpad middle click

https://github.com/wilu222/tripleclick
1•w222•8m ago•0 comments

How to Turn $4 into $351.0M

https://docshock.studio/research/follow-the-money/
2•docshock•10m ago•1 comments

Show HN: Podcast MCP

https://www.listennotes.com/api/mcp/
1•wenbin•10m ago•0 comments

Shield – Zero-dependency PII and secret masking for LLMs (MIT

https://github.com/PromptAudit-SaaS/shield
1•PromptSic•11m ago•0 comments

Changes on Freedesktop.org

https://blog.tenstral.net/2026/11/new-fdo-website.html
1•coryalthoff•11m ago•0 comments

Stop Committing Screenshot Noise

https://www.test2doc.com/blog/diff-detection/
1•speckx•11m ago•0 comments

William Shatner's Heavy Metal Album: WTF Is Heavy Metal?

https://wcsx.com/2026/10/20/william-shatners-heavy-metal-album/
1•Michelangelo11•13m ago•0 comments

Show HN: I built a risk map of the Army's planned lead azide detonation in Iowa

https://getlucera.com/iowa-lead-detonation
1•slawton3•14m ago•0 comments

Ask HN: NixOS, why no init freedom?

1•br0ceph•16m ago•1 comments

Practical cryptanalysis with MiniMax's latest Internal Model

https://www.minimax.io/blog/practical-cryptanalysis-with-minimaxs-latest-internal-model
2•dnw•16m ago•0 comments

Value Creation vs. Job Preservation

https://chrlschn.dev/blog/2026/11/value-creation-vs-job-preservation/
1•CharlieDigital•20m ago•0 comments

Silicon Valley Is Suffering from Model Collapse

https://www.reddit.com/r/technology/s/pd5TGWsYDf
3•sylvainkalache•23m ago•2 comments

The vibe-coding revolution is coming to all the gadgets

https://www.theverge.com/column/1039139/vibe-coding-gadgets-tv-camera
2•dkobia•23m ago•0 comments

Isaac Asimov: Jokester

https://lecturia.org/en/short-stories/isaac-asimov-jokester/29130/
2•thunderbong•23m ago•0 comments

But what is the Riemann hypothesis? Visualizing analytic continuation [video]

https://www.youtube.com/watch?v=sD0NjbwqlYw
1•binyu•23m ago•0 comments

Show HN: I distilled the brain of the 20Q handheld game into a website

https://20q.jordanscales.com/?r=1565-20#g=NNYSYYNSNYNSNYSYNSYNr
1•jordanscales•26m ago•0 comments

AetherSAST New IDE v2.7.0

https://maxxwwim.github.io/AetherSAST-150-CWE-MCP/
1•actheglitch•26m ago•0 comments

The cat that wouldn't die: The weird paradox of Schrödinger's cat

https://aeon.co/essays/no-schrodingers-cat-is-not-alive-and-dead-at-the-same-time
1•the-mitr•27m ago•0 comments

OpenTofu builds the house, Ansible furnishes it

https://ryancheley.com/2026/11/16/opentofu-builds-the-house-ansible-furnishes-it/
1•speckx•28m ago•0 comments

Compression of the RH Proof

https://riemann.verifytask.cn/
2•rzk•29m ago•0 comments

Famous Books That Were Written Under the Influence of Drugs

https://www.mentalfloss.com/literature/books/books-written-under-influence-drugs
4•ohjeez•30m ago•0 comments

Press START to prove your age

https://www.law.kuleuven.be/citip/blog/press-start-to-prove-your-age-how-the-eu-kids-act-could-ag...
2•jruohonen•31m ago•1 comments

All 84 public ARTEX forks and copies,with stars, version and last push

https://www.artex.sh/forks
1•Bender•31m ago•0 comments

How do you track '3x per week' habits without breaking streaks?

https://leewayhabits.netlify.app/
1•NoProbs•34m ago•0 comments