在 2020/11/27 下午4:14, Richard Biener 写道:
> 
> I prefer the ( on the next line.  The argument list can be two spaces
> indented from
> the function name or "right justified" (I think the latter looks
> visually better).
> 

The right justification thing looks reasonable. For example, I think this

```c++
basic_cow_string(const basic_cow_string& other)
  noexcept
  : 
m_sth(allocator_traits<allocator_type>::select_on_container_copy_construction(
                                                other.m_sth.as_allocator()))
  { this->assign(other);  }
```

looks better than

```c++
basic_cow_string(const basic_cow_string& other)
  noexcept
  : 
m_sth(allocator_traits<allocator_type>::select_on_container_copy_construction(
          other.m_sth.as_allocator()))
  { this->assign(other);  }
```

In the former fragment, indention of the 4th line is probably arbitrary. The 
only purpose is that,
if there wasn't a line break, the 3rd line would exceed a given length limit.

As you can see, qualified names in C++ can grow up to ~100 characters quite 
frequently. This may
deteriorate when `typename` and `template` are sometimes required. I don't 
think there is
practically a set of rules which governs all cases. So, if something looks 
better, go for it, and
that's why I think a (suggested) 100-char limit is better than the conventional 
80-char limit, which
forces another line break in front of `select_on_container_copy_construction`.


-- 
Best regards,
LH_Mouse

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to