Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Introduction

Welcome to the Co Programming documentation.

Co is still under active development, so its core features may be revised along the way. This document is the authoritative baseline for the final feature set.

This document is the foundational specification of Co. All language features of Co are defined against this document. Before reading it, please make sure you already have a programming background in other languages; this document mainly explains Co’s language features and is not a beginner’s programming tutorial.

Co is a new language extended from C. It stays as compatible as possible with existing C syntax rules, and additionally supports some object-oriented features. It can be roughly understood as Co ≈ C + object, or a simplified C++.

The default file extension of Co source files is .co.

All current syntax of Co is based on C, so anything not covered in this document follows the current C standard (C23 recommended, i.e. ISO/IEC 9899:2024). Wherever Co conflicts with or extends C, this document will describe it as clearly as possible.