explaingit

goplus/xgo

9,417GoAudience · developerComplexity · 3/5Setup · moderate

TLDR

XGo is a beginner-friendly programming language built on Go that removes boilerplate syntax and lets you call code written in C, C++, Python, and JavaScript from a single project.

Mindmap

mindmap
  root((xgo))
    What it does
      Simpler Go syntax
      Cross-language calls
      Beginner friendly
    Tech Stack
      Go compiler
      LLGo via LLVM
      WebAssembly
    Audiences
      Students
      Engineers
      Data scientists
    Use Cases
      Scripting without boilerplate
      Python interop
      Game development
    Resources
      Online playground
      Tutorial site
      Interactive prompt
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Write shorter, cleaner programs than Go requires with no need to declare packages or main functions for simple scripts.

USE CASE 2

Build data science tools in XGo that call existing Python libraries without switching languages.

USE CASE 3

Teach programming to students using a language that compiles to production-ready Go code.

USE CASE 4

Create WebAssembly modules that call C or JavaScript libraries using the LLGo companion compiler.

Tech stack

GoLLVMCC++PythonJavaScriptWebAssembly

Getting it running

Difficulty · moderate Time to first run · 30min

Default setup uses the standard Go compiler, LLGo for C, Python, and JavaScript interop requires a separate LLVM installation.

In plain English

XGo is a programming language designed to be simpler to read and write than most existing languages, with a stated goal of being approachable enough for beginners including students and children. It is built on top of Go, a programming language created by Google, and is fully compatible with it, meaning XGo code and Go code can live side by side in the same project. The language removes or shortens a lot of the structural requirements that Go and Python have. For example, you do not need to declare a main function or a package header to run a program. The syntax for common things like lists, maps, and string formatting is shorter and closer to plain writing. The README includes a comparison table showing how various Go patterns translate to shorter XGo equivalents. XGo is also designed to work with code written in other languages. Through a companion compiler called LLGo, which is based on a widely used compiler technology called LLVM, XGo programs can call libraries written in C, C++, Python, and JavaScript. This is aimed at areas like game development, data science, and running code on embedded hardware or in the browser via WebAssembly. The default setup uses the standard Go compiler, with LLGo as a future default. The project targets three audiences: working engineers who want a simpler language for large projects, students learning programming through a language they will actually use in professional work, and data scientists who want to share a common language with software engineers on their team. Documentation, a tutorial site, an online playground, and an interactive prompt where you can try XGo in the browser are all available through the project's website at xgo.dev. The source code is open and contributions are documented in a contributing guide in the repository.

Copy-paste prompts

Prompt 1
Show me a simple XGo program that reads a list of numbers and prints the average, without declaring a main function or package.
Prompt 2
How do I call a Python library from an XGo program using the LLGo compiler?
Prompt 3
Write an XGo equivalent of a Go program that reads a JSON file and filters entries, showing the syntax difference side by side.
Prompt 4
How do I install XGo on my machine and run my first script from the terminal?
Prompt 5
What is the XGo syntax for creating a map and looping over it compared to plain Go?
Open on GitHub → Explain another repo

← goplus on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.