Skip to content

Style Guide

Hannes Hauswedell edited this page Mar 6, 2017 · 2 revisions
  • if not otherwise stated, as in SeqAn2
  • snake_case instead of CamelCase, everything is always lower case!
  • template type parameters and publicly documented member type aliases shall end in _type
template <typename member_type>
struct foo
{
    member_type member{3};
    using other_member_type = uint32_t;
};
  • trait types shall end with _traits, e.g. align_file_out_default_traits
  • concepts shall end with _concept, e.g. virtual_suffix_tree_concept
  • trait type parameter thus will be named _traits_type and traits concepts will be named _traits_concept
template <typename foobar_traits_type = foobar_default_traits>
    requires foobar_traits_concept<foobar_traits_type>
struct foobar
{
    using foobar_traits_type::member_type;
    member_type member{3};
};
Clone this wiki locally