diff --git a/src/doc/trpl/SUMMARY.md b/src/doc/trpl/SUMMARY.md index 9d65f30e72379..f2eadc3c33e37 100644 --- a/src/doc/trpl/SUMMARY.md +++ b/src/doc/trpl/SUMMARY.md @@ -36,3 +36,4 @@ * [Macros](macros.md) * [Compiler Plugins](plugins.md) * [Conclusion](conclusion.md) +* [Glossary](glossary.md) diff --git a/src/doc/trpl/glossary.md b/src/doc/trpl/glossary.md new file mode 100644 index 0000000000000..156f33748673b --- /dev/null +++ b/src/doc/trpl/glossary.md @@ -0,0 +1,16 @@ +% Glossary + +Not every Rustacean has a background in systems programming, nor in computer +science, so we've added explanations of terms that might be unfamiliar. + +### Arity + +Arity refers to the number of arguments a function or operation takes. + +```rust +let x = (2, 3); +let y = (4, 6); +let z = (8, 2, 6); +``` + +In the example above `x` and `y` have arity 2. `z` has arity 3.