Go to file
Nick Cameron ea7e6e7bb8
Merge pull request #63 from dubek/patch-1
idioms/option-iter: Fix typo in `extend` example
2017-11-29 08:11:48 +13:00
anti_patterns add links to deny(warnings) antipattern, fix typo (#52) 2017-01-24 08:06:21 +13:00
idioms option-iter: Fix typo in extend example 2017-11-28 11:11:23 +02:00
patterns fixed link to "Builders" (#56) 2017-05-18 07:52:07 +12:00
intro.md Initial commit 2015-08-31 10:06:10 +12:00
LICENSE Initial commit 2015-08-31 10:06:10 +12:00
README.md add links to deny(warnings) antipattern, fix typo (#52) 2017-01-24 08:06:21 +13:00
template.md Added a few idioms and patterns - some are still WIP 2015-10-23 09:53:16 +13:00

Rust Design Patterns

An open source repository of design patterns and idioms in the Rust programming language.

Contents

Introduction

Idioms

Design patterns

Anti-patterns

  • TODO thread + catch_panic for exceptions
  • TODO Clone to satisfy the borrow checker
  • Deref polymorphism
  • TODO Matching all fields of a struct (back compat)
  • TODO wildcard matches
  • TODO taking an enum rather than having multiple functions
  • TODO unwrap()ing every Result instead of forwarding it
  • #[deny(warnings)]

Contributing

Contributions are very welcome!

You should start with the template. Copy it into the appropriate directory, edit it, and submit a PR. You might not want every section, and you might want to add extra sections.

We suggest leaving a comment on the issue tracker so that other people don't start working on the same topic.

Correction and elaboration PRs are very welcome.