frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Motus: A Unified Latent Action World Model

https://arxiv.org/abs/2512.13030
1•mnming•30s ago•0 comments

Rotten Tomatoes Desperately Claims 'Impossible' Rating for 'Melania' Is Real

https://www.thedailybeast.com/obsessed/rotten-tomatoes-desperately-claims-impossible-rating-for-m...
1•juujian•2m ago•0 comments

The protein denitrosylase SCoR2 regulates lipogenesis and fat storage [pdf]

https://www.science.org/doi/10.1126/scisignal.adv0660
1•thunderbong•4m ago•0 comments

Los Alamos Primer

https://blog.szczepan.org/blog/los-alamos-primer/
1•alkyon•6m ago•0 comments

NewASM Virtual Machine

https://github.com/bracesoftware/newasm
1•DEntisT_•8m ago•0 comments

Terminal-Bench 2.0 Leaderboard

https://www.tbench.ai/leaderboard/terminal-bench/2.0
1•tosh•9m ago•0 comments

I vibe coded a BBS bank with a real working ledger

https://mini-ledger.exe.xyz/
1•simonvc•9m ago•1 comments

The Path to Mojo 1.0

https://www.modular.com/blog/the-path-to-mojo-1-0
1•tosh•12m ago•0 comments

Show HN: I'm 75, building an OSS Virtual Protest Protocol for digital activism

https://github.com/voice-of-japan/Virtual-Protest-Protocol/blob/main/README.md
4•sakanakana00•15m ago•0 comments

Show HN: I built Divvy to split restaurant bills from a photo

https://divvyai.app/
3•pieterdy•17m ago•0 comments

Hot Reloading in Rust? Subsecond and Dioxus to the Rescue

https://codethoughts.io/posts/2026-02-07-rust-hot-reloading/
3•Tehnix•18m ago•1 comments

Skim – vibe review your PRs

https://github.com/Haizzz/skim
2•haizzz•19m ago•1 comments

Show HN: Open-source AI assistant for interview reasoning

https://github.com/evinjohnn/natively-cluely-ai-assistant
4•Nive11•20m ago•6 comments

Tech Edge: A Living Playbook for America's Technology Long Game

https://csis-website-prod.s3.amazonaws.com/s3fs-public/2026-01/260120_EST_Tech_Edge_0.pdf?Version...
2•hunglee2•23m ago•0 comments

Golden Cross vs. Death Cross: Crypto Trading Guide

https://chartscout.io/golden-cross-vs-death-cross-crypto-trading-guide
2•chartscout•26m ago•0 comments

Hoot: Scheme on WebAssembly

https://www.spritely.institute/hoot/
3•AlexeyBrin•29m ago•0 comments

What the longevity experts don't tell you

https://machielreyneke.com/blog/longevity-lessons/
2•machielrey•30m ago•1 comments

Monzo wrongly denied refunds to fraud and scam victims

https://www.theguardian.com/money/2026/feb/07/monzo-natwest-hsbc-refunds-fraud-scam-fos-ombudsman
3•tablets•35m ago•1 comments

They were drawn to Korea with dreams of K-pop stardom – but then let down

https://www.bbc.com/news/articles/cvgnq9rwyqno
2•breve•37m ago•0 comments

Show HN: AI-Powered Merchant Intelligence

https://nodee.co
1•jjkirsch•39m ago•0 comments

Bash parallel tasks and error handling

https://github.com/themattrix/bash-concurrent
2•pastage•39m ago•0 comments

Let's compile Quake like it's 1997

https://fabiensanglard.net/compile_like_1997/index.html
2•billiob•40m ago•0 comments

Reverse Engineering Medium.com's Editor: How Copy, Paste, and Images Work

https://app.writtte.com/read/gP0H6W5
2•birdculture•46m ago•0 comments

Go 1.22, SQLite, and Next.js: The "Boring" Back End

https://mohammedeabdelaziz.github.io/articles/go-next-pt-2
1•mohammede•51m ago•0 comments

Laibach the Whistleblowers [video]

https://www.youtube.com/watch?v=c6Mx2mxpaCY
1•KnuthIsGod•53m ago•1 comments

Slop News - The Front Page right now but it's only Slop

https://slop-news.pages.dev/slop-news
1•keepamovin•57m ago•1 comments

Economists vs. Technologists on AI

https://ideasindevelopment.substack.com/p/economists-vs-technologists-on-ai
1•econlmics•59m ago•0 comments

Life at the Edge

https://asadk.com/p/edge
4•tosh•1h ago•0 comments

RISC-V Vector Primer

https://github.com/simplex-micro/riscv-vector-primer/blob/main/index.md
4•oxxoxoxooo•1h ago•1 comments

Show HN: Invoxo – Invoicing with automatic EU VAT for cross-border services

2•InvoxoEU•1h ago•0 comments
Open in hackernews

Ask HN: Testing AST or assembly output for a compiler

2•backslash_16•3mo ago
Hi Hacker News,

I'm working on a c compiler from scratch and am in a bit of a deadzone figuring out how I can test the generated AST and assembly output. I'm specifically having a hard time finding something that is viable for a one person project and which is also useful.

I did some research on Clang and saw they use a custom Filecheck library. This looks incredible for a production grade compiler but for mine I'm not sure if I want to put in all of the effort (especially because my host language F# doesn't have a Filecheck lib and I would have to re-create it).

Same with the AST - the best I can think of is creating the nodes in my host code language. This is verbose.

What have you done to test and check your compiler output, any good recommendations for me? I'm happy to research or read anything. Please keep in mind I'm going for a good effort to reward ratio.

Comments

nicohayes•3mo ago
Honestly, I think the biggest win is just having a solid test harness that can compare AST snapshots across versions. It’s not glamorous, but it catches regressions early and gives you confidence when you refactor the optimizer. Maybe throw in some fuzzing on the AST nodes and see what breaks – it’s surprisingly fun.
Jtsummers•3mo ago
You can try creating an interpreter for the AST and other IR forms you use. This can also free you from testing for specific generated ASTs and IR, so long as they're equivalent (when executed will produce the same results). This will be more helpful once you start with things like adding in optimization passes.
keyle•3mo ago
I go straight to having examples/ with a ton of little test cases, and check the output stdout and stderr to see whether it went pear shaped.

It's an end to end test harness of sorts.

If you care about locking down your AST and IR output, I'd recommend having a printer of sort to stdout and check against that, like a sha-1 or expected output.txt to compare against, see example [1]

[1] https://pastebin.com/ZA6CKwPZ