From 21a3514e7321937fe9346306039b3f208ac9ad89 Mon Sep 17 00:00:00 2001 From: ZzoxAA Date: Wed, 20 Jan 2021 10:46:27 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BB=A3=E7=A0=81=E4=B8=AD=E6=B7=B7=E5=85=A5?= =?UTF-8?q?=E4=BA=86=E4=B8=AD=E6=96=87=E6=8B=AC=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- README_en.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 9c2678e..3e230c2 100644 --- a/README.md +++ b/README.md @@ -496,7 +496,7 @@ int main() A a5 = (A)1; // OK:允许 static_cast 的显式转换 doA(1); // OK:允许从 int 到 A 的隐式转换 if (a1); // OK:使用转换函数 A::operator bool() 的从 A 到 bool 的隐式转换 - bool a6(a1); // OK:使用转换函数 A::operator bool() 的从 A 到 bool 的隐式转换 + bool a6(a1); // OK:使用转换函数 A::operator bool() 的从 A 到 bool 的隐式转换 bool a7 = a1; // OK:使用转换函数 A::operator bool() 的从 A 到 bool 的隐式转换 bool a8 = static_cast(a1); // OK :static_cast 进行直接初始化 diff --git a/README_en.md b/README_en.md index 90fc508..2b333a6 100644 --- a/README_en.md +++ b/README_en.md @@ -500,7 +500,7 @@ int main() A a5 = (A)1; // OK:Allow explicit conversion of static_cast doA(1); // OK:Allow implicit conversion from int to A if (a1); // OK: implicit conversion from A to bool using conversion function A ::operator bool() - bool a6(a1); // OK: implicit conversion from A to bool using conversion function A::operator bool() + bool a6(a1); // OK: implicit conversion from A to bool using conversion function A::operator bool() bool a7 = a1; // OK: implicit conversion from A to bool using conversion function A::operator bool() bool a8 = static_cast(a1); // OK: static_cast for direct initialization