Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Zig (Compiler Diagnostics)New to Visual Studio Code? Get it now.
Zig (Compiler Diagnostics)

Zig (Compiler Diagnostics)

Tom Sykes

|
1 install
| (0) | Free
Zig language server that provides real compiler diagnostics via zig run
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

# Zig Compiler Diagnostics

This extension provides **real Zig compiler diagnostics** inside VS Code by

running the Zig compiler directly instead of relying on zig ast-check.

It exists because zig ast-check misses valid compile-time errors.

## Features

- Uses zig build-exe main.zig -fno-emit-bin to surface **real compiler errors**

- Automatically locates main.zig:

  - current file

  - current directory

  - parent directories (up to a few levels)

- Proper LSP diagnostics with line and column highlighting

- Works alongside zls

## How it Works

On file save:

1. Finds the nearest main.zig

2. Runs:

  ```bash

  zig build-exe main.zig -fno-emit-bin

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft