Coding a C compiler in Javascript

Publicado em: 03 Julho 2025
no canal de: dr Jonas Birch
6,192
367

In this exciting new project we'll be coding a real C compiler in Javascript. The first version will be able to parse a few commands and when all the steps are done (pre-processing, lexing, defining grammar,parsing,emitting) we will add new functionality, one command at the time.

To follow along in this project you need a basic understanding of Javascript. That's it. Everything Node- or Typescript related I will explain at every step.

This project will work equally well in Windows, Mac OS or Linux. All you need is Node.js and Nasm. Just follow the instructions from the intro.

Happy coding!

JB

References

1. Buy the "C compiler in Javascript" course (16 episodes) at a great discount:
https://courses.doctorbirch.com/d4224...

2. Buy my book at a discount for a few more days, use this coupon code:
https://books.doctorbirch.com/57aa8f1...

3. Become a channel member and get several benefits, check out:
   / @dr-jonas-birch  

4. Source code from the repo (check out the jaycc/ folder)
https://repo.doctorbirch.com

Table of Contents

00:00:00 Project setup
00:07:57 Defining token datastructures
00:38:05 Coding the lexer
01:29:36 Testing/troubleshooting
01:45:45 First 🍒
02:02:35 The lexer works! 🍒


Nesta página do site você pode assistir ao vídeo on-line Coding a C compiler in Javascript duração hora minuto segundo em boa qualidade , que foi baixado pelo usuário dr Jonas Birch 03 Julho 2025, compartilhe o link com seus amigos e conhecidos, no youtube este vídeo já foi visto 6,192 vezes e gostou 367 espectadores. Boa visualização!