PingCAP Style Guide

Guide to writing idiomatic code at PingCAP and in the TiKV project.


Project maintained by pingcap Hosted on GitHub Pages — Theme by mattgraham

Modules and crates

Module structure

Rationale

Privacy and visibility

What to import

See also formatting/imports.

Rationale

Crates

Rationale

Dependencies

There are costs and benefits to adding dependencies, both small and large. There are few absolutes, but here are some things to consider when adding a new dependency:

Some other considerations for dependencies:

Rationale

Cargo.toml

<< Comments | Data structures >>