Skip to content

[Codestyle] Use of spaces around operators #7

@Flamefire

Description

@Flamefire

I know codestyle is highly subjective, but I'd like to make a suggestion:

Would you mind adopting a codestyle with spaces around operators?
Without those it looks like a token soup that is hard to parse visually for me.

E.g.:

  • for(std::size_t i=0;i<k/8;++i){
  • x?1+constexpr_bit_width(x>>1):0;
  • x|=Block(1)<<(h&mask);

could be:

  • for(std::size_t i = 0; i < k / 8; ++i){
  • x ? 1 + constexpr_bit_width(x >> 1) : 0;
  • x |= Block(1) << (h&mask);

Or at least for "delimiters"

  • for(std::size_t i=0; i<k/8; ++i){
  • x ? 1+constexpr_bit_width(x>>1) : 0;
  • x |= Block(1)<<(h&mask);

To me this makes it much easier to see which parts belong together and not miss e.g. the "?", "|" or ";"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions