blog

My blog at www.shimmy1996.com

git clone git://git.shimmy1996.com/blog.git
commit cfaf9128bb7fa302f4004b018aa95415a76f3c7e
parent 9915ca264cbe96c16f10620d076dd9a2ed415445
Author: Shimmy Xu <shimmy.xu@shimmy1996.com>
Date:   Sat,  3 Apr 2021 16:54:43 -0500

Fix typo

Diffstat:
Mcontent/now.ja.md | 2+-
Mcontent/now.zh.md | 2+-
Mcontent/posts/2019-04-27-enumerate-with-c-plus-plus.en.md | 4++--
Mcontent/posts/2019-04-27-enumerate-with-c-plus-plus.zh.md | 4++--
Morg/2019.org | 8++++----
Morg/fixed.org | 4++--
6 files changed, 12 insertions(+), 12 deletions(-)
diff --git a/content/now.ja.md b/content/now.ja.md
@@ -5,7 +5,7 @@ slug = "now"
 draft = false
 +++
 
-## 2020年目標 {#2020年目標}
+## 2021年目標 {#2021年目標}
 
 -   ☐ 技術類以外の記事を書くこと。<code>[1/4]</code>
 -   ☐ 1500マイルをサイクリングすろこと。<code>[271/1500]</code>
diff --git a/content/now.zh.md b/content/now.zh.md
@@ -5,7 +5,7 @@ slug = "now"
 draft = false
 +++
 
-## 2020年目标 {#2020年目标}
+## 2021年目标 {#2021年目标}
 
 -   ☐ 写非技术性日志。<code>[1/4]</code>
 -   ☐ 骑车1500英里。<code>[271/1500]</code>
diff --git a/content/posts/2019-04-27-enumerate-with-c-plus-plus.en.md b/content/posts/2019-04-27-enumerate-with-c-plus-plus.en.md
@@ -68,10 +68,10 @@ for (auto i = 0; auto elem : v) {
 Meh, not that impressive. The new `<ranges>` library provides a more appealing way to achieve this:
 
 ```c++
-for (auto [i, elem] : v | std::view::transform(
+for (auto [i, elem] : v | std::views::transform(
          [i = 0](auto elem) mutable { return std::tuple{i++, elem}; })) {
     std::cout << i << ", " << elem << std::endl;
 }
 ```
 
-I like the structured binding method and the `<ranges>` based method the most. It would be even better though if we can get a `std::view::enumerate` to solve this problem once and for all.
+I like the structured binding method and the `<ranges>` based method the most. It would be even better though if we can get a `std::views::enumerate` to solve this problem once and for all.
diff --git a/content/posts/2019-04-27-enumerate-with-c-plus-plus.zh.md b/content/posts/2019-04-27-enumerate-with-c-plus-plus.zh.md
@@ -68,10 +68,10 @@ for (auto i = 0; auto elem : v) {
 新加入的 `<ranges>` 库则提供了一种更加吸引人的实现方法:
 
 ```c++
-for (auto [i, elem] : v | std::view::transform(
+for (auto [i, elem] : v | std::views::transform(
          [i = 0](auto elem) mutable { return std::tuple{i++, elem}; })) {
     std::cout << i << ", " << elem << std::endl;
 }
 ```
 
-我最喜欢基于结构化绑定和 `<ranges>` 库的方法。当然如果要是有 `std::view::enumerate` 来一劳永逸地解决这个问题就最好不过了。
+我最喜欢基于结构化绑定和 `<ranges>` 库的方法。当然如果要是有 `std::views::enumerate` 来一劳永逸地解决这个问题就最好不过了。
diff --git a/org/2019.org b/org/2019.org
@@ -299,13 +299,13 @@ In C++20, we have the ability to add an init-statement in ranged-based for loops
 #+END_SRC
 Meh, not that impressive. The new =<ranges>= library provides a more appealing way to achieve this:
 #+BEGIN_SRC c++
-  for (auto [i, elem] : v | std::view::transform(
+  for (auto [i, elem] : v | std::views::transform(
            [i = 0](auto elem) mutable { return std::tuple{i++, elem}; })) {
       std::cout << i << ", " << elem << std::endl;
   }
 #+END_SRC
 
-I like the structured binding method and the =<ranges>= based method the most. It would be even better though if we can get a =std::view::enumerate= to solve this problem once and for all.
+I like the structured binding method and the =<ranges>= based method the most. It would be even better though if we can get a =std::views::enumerate= to solve this problem once and for all.
 
 ** DONE zh
 :PROPERTIES:
@@ -364,13 +364,13 @@ I like the structured binding method and the =<ranges>= based method the most. I
 #+END_SRC
 新加入的 =<ranges>= 库则提供了一种更加吸引人的实现方法:
 #+BEGIN_SRC c++
-  for (auto [i, elem] : v | std::view::transform(
+  for (auto [i, elem] : v | std::views::transform(
            [i = 0](auto elem) mutable { return std::tuple{i++, elem}; })) {
       std::cout << i << ", " << elem << std::endl;
   }
 #+END_SRC
 
-我最喜欢基于结构化绑定和 =<ranges>= 库的方法。当然如果要是有 =std::view::enumerate= 来一劳永逸地解决这个问题就最好不过了。
+我最喜欢基于结构化绑定和 =<ranges>= 库的方法。当然如果要是有 =std::views::enumerate= 来一劳永逸地解决这个问题就最好不过了。
 
 * DONE Hello Darkness, My Old Friend
 :PROPERTIES:
diff --git a/org/fixed.org b/org/fixed.org
@@ -160,7 +160,7 @@ CLOSED: [2021-01-01 Fri 17:35]
 :EXPORT_FILE_NAME: now.zh.md
 :END:
 
-*** 2020年目标
+*** 2021年目标
 - ☐ 写非技术性日志。[1/4]
 - ☐ 骑车1500英里。[271/1500]
 - ☐ 给时间记账。
@@ -182,7 +182,7 @@ CLOSED: [2021-01-01 Fri 17:35]
 :EXPORT_FILE_NAME: now.ja.md
 :END:
 
-*** 2020年目標
+*** 2021年目標
 - ☐ 技術類以外の記事を書くこと。[1/4]
 - ☐ 1500マイルをサイクリングすろこと。[271/1500]
 - ☐ 時間の使い方を記録すること。