Giter Site home page Giter Site logo

lambdaxs / ugo-compiler-book Goto Github PK

View Code? Open in Web Editor NEW

This project forked from wa-lang/ugo-compiler-book

1.0 0.0 0.0 8.66 MB

:books: µGo语言实现(从头开发一个迷你Go语言编译器)

Home Page: https://wa-lang.org/ugo-compiler-book

Go 100.00%

ugo-compiler-book's Introduction

《µGo语言实现——从头开发一个迷你Go语言编译器》


本书尝试以实现 µGo 编译器为线索,以边学习边完善的自举方式实现一个玩具语言。


What: µGo 例子

package main

import "libc"
import m "libc.math"

const Pi = 3.14
const Pi_2 = Pi * 2

type MyInt int
type MyInt2 = int

var x = println(1 + 2*(3+4) + -10 + double(50))

func println() int

func main() int {}

Output: 输出的目标格式

为了跨平台和方便测试,输出LLVM汇编代码,如果以后可能会增加WASM文件。

License 版权

学习目的可在 Github 平台免费阅读。

ugo-compiler-book's People

Contributors

chai2010 avatar ojdev avatar jancd avatar mengzhuo avatar igmainc avatar myrfy001 avatar xiehengjian avatar clamyang avatar

Stargazers

xiaos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.