Skip to content

Commit bc9306a

Browse files
Merge pull request #1546 from cpprefjp/fix/reference
standardizing to `const T& v` type declaration
2 parents 5b45457 + e42919d commit bc9306a

File tree

10 files changed

+10
-10
lines changed

10 files changed

+10
-10
lines changed

lang/cpp11/defaulted_and_deleted_functions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ int main()
8989
sometype();
9090

9191
// デフォルト動作のコピーコンストラクタを使用する
92-
sometype(const sometype &) = default;
92+
sometype(const sometype&) = default;
9393

9494
// デフォルト動作のデストラクタを使用する。
9595
// ただし、このデストラクタは仮想関数とする。

lang/cpp26/allowing_exception_throwing_in_constant-evaluation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ const auto b = hello("Hana");
2828

2929
try {
3030
const auto c = hello(""); // C++26: 例外を捕捉
31-
} catch (const validation_error &) {
31+
} catch (const validation_error&) {
3232
// everything is fine
3333
}
3434

lang/cpp26/constexpr_cast_from_voidptr.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ private:
3434
std::string_view (*speak_function)(const void*);
3535
public:
3636
template <typename Animal>
37-
constexpr AnimalView(const Animal &a)
37+
constexpr AnimalView(const Animal& a)
3838
: animal{&a}, speak_function{[](const void* object) {
3939
return static_cast<const Animal*>(object)->speak();
4040
}}

reference/map/map/at.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
```cpp
99
T& at(const key_type& x); // (1) C++11
10-
const T& at(const key_type & x) const; // (2) C++11
10+
const T& at(const key_type& x) const; // (2) C++11
1111

1212
template<class K>
1313
T& at(const K& x); // (3) C++26

reference/set/multiset/extract.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ struct my_struct // ムーブオンリーな型
5656
int num = 0;
5757
static inline int count = 0;
5858
constexpr my_struct(int i) noexcept : value(i) { num = count++; };
59-
bool operator < (const my_struct &rhs) const noexcept {return this->value < rhs.value;}
59+
bool operator < (const my_struct& rhs) const noexcept {return this->value < rhs.value;}
6060
};
6161
6262
int main()

reference/set/set/extract.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ struct my_struct // ムーブオンリーな型
5454
: private noncopyable {
5555
int value;
5656
constexpr explicit my_struct(int i) noexcept : value(i) {};
57-
bool operator < (const my_struct &rhs) const noexcept {return this->value < rhs.value;}
57+
bool operator < (const my_struct& rhs) const noexcept {return this->value < rhs.value;}
5858
};
5959
6060
int main()

reference/tuple/ignore.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
namespace std {
99
struct ignore-type { // 説明用の定義 (C++26)
1010
constexpr const ignore-type&
11-
operator=(const auto &) const noexcept
11+
operator=(const auto&) const noexcept
1212
{ return *this; }
1313
};
1414

reference/unordered_map/unordered_map/at.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
```cpp
99
T& at(const key_type& x); // (1) C++11
10-
const T& at(const key_type & x) const; // (2) C++11
10+
const T& at(const key_type& x) const; // (2) C++11
1111

1212
template<class K>
1313
T& at(const K& x); // (3) C++26

reference/unordered_set/unordered_multiset/extract.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ struct my_struct // ムーブオンリーな型
4747
int num = 0;
4848
static inline int count = 0;
4949
constexpr my_struct(int i) noexcept : value(i) { num = count++; };
50-
bool operator == (const my_struct &rhs) const noexcept {return this->value == rhs.value;}
50+
bool operator == (const my_struct& rhs) const noexcept {return this->value == rhs.value;}
5151
};
5252
5353
// ハッシュ関数

reference/unordered_set/unordered_set/extract.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ struct my_struct // ムーブオンリーな型
4747
int num = 0;
4848
static inline int count = 0;
4949
constexpr my_struct(int i) noexcept : value(i) { num = count++; };
50-
bool operator == (const my_struct &rhs) const noexcept {return this->value == rhs.value;}
50+
bool operator == (const my_struct& rhs) const noexcept {return this->value == rhs.value;}
5151
};
5252
5353
// ハッシュ関数

0 commit comments

Comments
 (0)