{"id":7487,"date":"2026-07-24T13:34:15","date_gmt":"2026-07-24T05:34:15","guid":{"rendered":"https:\/\/i007.cc\/wordpress\/?p=7487"},"modified":"2026-07-24T13:34:15","modified_gmt":"2026-07-24T05:34:15","slug":"https-github-com-netcan-asyncio-%e8%bf%99%e4%b8%aa%e9%a1%b9%e7%9b%ae%e8%a7%a3%e5%86%b3%e4%ba%86%e4%bb%80%e4%b9%88%e9%97%ae%e9%a2%98%ef%bc%9f%e6%9c%89%e4%bb%80%e4%b9%88%e5%8e%9f%e5%88%9b%e6%80%a7","status":"publish","type":"post","link":"https:\/\/i007.cc\/wordpress\/archives\/7487","title":{"rendered":"https:\/\/github.com\/netcan\/asyncio \u8fd9\u4e2a\u9879\u76ee\u89e3\u51b3\u4e86\u4ec0\u4e48\u95ee\u9898\uff1f\u6709\u4ec0\u4e48\u539f\u521b\u6027\uff1f"},"content":{"rendered":"<div data-rs-index=\"8\" data-index=\"8\">\n<div tabindex=\"0\" role=\"article\" aria-setsize=\"10\" aria-posinset=\"9\" aria-label=\"Message 9 of 10\">\n<div data-test-render-count=\"2\">\n<div class=\"mb-1 mt-[var(--msg-gap,1.5rem)] group group\/message-row\">\n<div class=\"flex flex-col items-end gap-1\">\n<div class=\"group relative inline-flex gap-2 bg-bg-300 dark:[[data-darker-default]_&amp;]:bg-bg-000 rounded-xl pl-2.5 py-[var(--msg-bubble-py,0.625rem)] break-words text-text-100 transition-all max-w-[75ch] flex-col !px-[var(--msg-bubble-px,1rem)] max-w-[85%]\" data-user-message-bubble=\"true\">\n<div class=\"flex flex-row gap-2 relative\">\n<div class=\"flex-1\">\n<div class=\"font-large !font-user-message py-0.5 grid grid-cols-1 gap-2 relative [&amp;_ul]:!space-y-0 [&amp;_ol]:!space-y-0 [&amp;_ul]:pl-8 [&amp;_ol]:pl-8\" data-testid=\"user-message\"><\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<div data-rs-index=\"9\" data-index=\"9\" data-last-message=\"true\">\n<div tabindex=\"-1\" role=\"article\" aria-setsize=\"10\" aria-posinset=\"10\" aria-label=\"Message 10 of 10\">\n<div data-test-render-count=\"1\">\n<div class=\"group group\/message-row\">\n<div class=\"group relative relative pb-[var(--msg-assistant-pb,0.75rem)]\" data-is-streaming=\"false\">\n<div class=\"font-claude-response relative leading-[1.65rem] [&amp;_pre&gt;div]:bg-bg-000\/50 [&amp;_pre&gt;div]:border-0.5 [&amp;_pre&gt;div]:border-border-400 [&amp;_.ignore-pre-bg&gt;div]:bg-transparent [&amp;_.standard-markdown_:is(p,blockquote,h1,h2,h3,h4,h5,h6)]:pl-2 [&amp;_.standard-markdown_:is(p,blockquote,ul,ol,h1,h2,h3,h4,h5,h6)]:pr-8 [&amp;_.progressive-markdown_:is(p,blockquote,h1,h2,h3,h4,h5,h6)]:pl-2 [&amp;_.progressive-markdown_:is(p,blockquote,ul,ol,h1,h2,h3,h4,h5,h6)]:pr-8\">\n<div class=\"grid grid-rows-[auto_auto] min-w-0\">\n<div class=\"row-start-2 col-start-1 relative grid grid-rows-[auto_auto] isolate min-w-0\">\n<div class=\"row-start-1 col-start-1 relative z-[2] min-w-0\">\n<div class=\"standard-markdown grid-cols-1 grid [&amp;_&gt;_*]:min-w-0 gap-3 [&amp;_&gt;_*:last-child]:mb-0 print:block print:[&amp;_&gt;_*_+_*]:mt-3 standard-markdown\">\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u8fd9\u662f\u4e2a\u5f88\u503c\u5f97\u6df1\u6316\u7684\u9879\u76ee\u3002\u7efc\u5408\u6765\u770b\uff0c\u5b83\u7684\u539f\u521b\u6027\u6bd4\u540d\u5b57\u6697\u793a\u7684\u66f4\u6709\u5b9e\u8d28\u6027\u3002<\/p>\n<hr class=\"border-border-200 border-t-0.5 my-3 mx-1.5\" \/>\n<h3 class=\"text-text-100 mt-3 -mb-1 text-[1.125rem] font-bold\" dir=\"ltr\">\u5b83\u89e3\u51b3\u4e86\u4ec0\u4e48\u95ee\u9898<\/h3>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">C++20 \u5728\u8bed\u8a00\u5c42\u9762\u52a0\u5165\u4e86\u534f\u7a0b\uff08coroutines\uff09\uff0c\u4f46\u53ea\u7ed9\u4e86\u4f60\u539f\u59cb\u673a\u5236\uff1a<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">co_await<\/code>\u3001<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">co_yield<\/code>\u3001<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">co_return<\/code>\u00a0\u8fd9\u4e9b\u5173\u952e\u5b57\uff0c\u4ee5\u53ca\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">promise_type<\/code>\u3001<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">coroutine_handle<\/code>\u00a0\u8fd9\u4e9b\u5e95\u5c42\u63a5\u53e3\u3002<strong>\u6807\u51c6\u59d4\u5458\u4f1a\u6545\u610f\u4e0d\u63d0\u4f9b\u8fd0\u884c\u65f6<\/strong>\u2014\u2014\u6ca1\u6709\u4e8b\u4ef6\u5faa\u73af\u3001\u6ca1\u6709\u4efb\u52a1\u8c03\u5ea6\u5668\u3001\u6ca1\u6709 I\/O \u539f\u8bed\u3001\u6ca1\u6709\u540c\u6b65\u5de5\u5177\u3002<\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u8fd9\u610f\u5473\u7740\u4efb\u4f55\u60f3\u7528 C++20 \u534f\u7a0b\u505a\u5f02\u6b65\u7f16\u7a0b\u7684\u4eba\uff0c\u90fd\u5fc5\u987b\u81ea\u5df1\u5b9e\u73b0\u6574\u5957\u8fd0\u884c\u65f6\u57fa\u7840\u8bbe\u65bd\u3002\u800c\u6b63\u786e\u5b9e\u73b0\u8fd9\u4e9b\u4e1c\u897f\u6781\u5176\u590d\u6742\uff1a\u534f\u7a0b\u5e27\u7684\u751f\u547d\u5468\u671f\u7ba1\u7406\u3001\u6302\u8d77\u70b9\u7684\u6240\u6709\u6743\u8bed\u4e49\u3001\u53d6\u6d88\u4f20\u64ad\u7684\u6b63\u786e\u6027\u2026\u2026\u6bcf\u4e00\u9879\u90fd\u662f\u8db3\u4ee5\u8e29\u5751\u6570\u5468\u7684\u9886\u57df\u3002<\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">netcan\/asyncio \u505a\u7684\u5c31\u662f\u628a\u8fd9\u5957\u8fd0\u884c\u65f6\u57fa\u7840\u8bbe\u65bd\u505a\u51fa\u6765\uff0c\u5e76\u4e14\u9009\u62e9\u4e86\u4e00\u4e2a\u5177\u4f53\u7684 API \u8bbe\u8ba1\u76ee\u6807\uff1a<strong>\u8ba9 C++ \u7684\u5f02\u6b65\u4ee3\u7801\u770b\u8d77\u6765\u548c Python asyncio \u4e00\u6a21\u4e00\u6837<\/strong>\u3002<\/p>\n<div class=\"relative group\/copy bg-bg-000\/50 border-0.5 border-border-400 rounded-lg focus:outline-none focus-visible:ring-2 focus-visible:ring-accent-100\" tabindex=\"0\" role=\"group\" aria-label=\"cpp code\">\n<div class=\"sticky opacity-0 group-hover\/copy:opacity-100 group-focus-within\/copy:opacity-100 top-2 py-2 h-12 w-0 float-right\">\n<div class=\"absolute right-0 h-8 px-2 items-center inline-flex z-10\"><\/div>\n<\/div>\n<div class=\"text-text-500 font-small p-3.5 pb-0\">cpp<\/div>\n<div class=\"overflow-x-auto\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">\/\/ Python:\r\nresults = await asyncio.gather(task_a(), task_b(), task_c())\r\n\r\n\/\/ netcan\/asyncio C++:\r\nauto [a, b, c] = co_await asyncio::gather(task_a(), task_b(), task_c());<\/pre>\n<p>&nbsp;<\/p>\n<\/div>\n<\/div>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u8fd9\u4e0d\u53ea\u662f\u6539\u4e2a\u540d\u5b57\uff0c<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">gather()<\/code>\u00a0\u8fd4\u56de\u7684\u662f\u7f16\u8bd1\u671f\u786e\u5b9a\u7c7b\u578b\u7684 tuple\uff0c\u7528 C++17 \u7ed3\u6784\u5316\u7ed1\u5b9a\u76f4\u63a5\u89e3\u5305\uff0c\u7c7b\u578b\u5b89\u5168\uff0c\u96f6\u5f00\u9500\u3002<\/p>\n<hr class=\"border-border-200 border-t-0.5 my-3 mx-1.5\" \/>\n<h3 class=\"text-text-100 mt-3 -mb-1 text-[1.125rem] font-bold\" dir=\"ltr\">\u6709\u54ea\u4e9b\u539f\u521b\u6027<\/h3>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\"><strong>1. \u7528\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">await_transform<\/code>\u00a0+\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">std::source_location<\/code>\u00a0\u5b9e\u73b0\u5f02\u6b65\u8c03\u7528\u6808\u8fd8\u539f\uff08\u6700\u72ec\u7279\u7684\u6280\u672f\u70b9\uff09<\/strong><\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u534f\u7a0b\u6700\u8ba9\u5f00\u53d1\u8005\u5934\u75bc\u7684\u8c03\u8bd5\u95ee\u9898\u662f\uff1a\u4f20\u7edf\u8c03\u7528\u6808\u5728\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">co_await<\/code>\u00a0\u5904\u65ad\u88c2\uff0c\u56e0\u4e3a\u534f\u7a0b\u5e27\u5728\u5806\u4e0a\uff0c\u6302\u8d77\u540e\u6808\u5e27\u5df2\u7ecf\u4e0d\u5b58\u5728\u4e86\u3002\u8c03\u8bd5\u5668\u53ea\u80fd\u770b\u5230\u5f53\u524d\u5e27\uff0c\u5b8c\u5168\u4e0d\u77e5\u9053&#8221;\u662f\u8c01\u53d1\u8d77\u4e86\u8fd9\u4e2a await&#8221;\u3002<\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">netcan\/asyncio \u7684\u89e3\u6cd5\u662f\uff1a\u5728\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">promise_type<\/code>\u00a0\u91cc\u91cd\u8f7d\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">await_transform()<\/code>\u2014\u2014C++ \u534f\u7a0b\u89c4\u5b9a\u6bcf\u4e00\u6b21\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">co_await<\/code>\u00a0\u90fd\u4f1a\u5148\u7ecf\u8fc7\u8fd9\u4e2a\u51fd\u6570\u2014\u2014\u5728\u8fd9\u91cc\u7528\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">std::source_location::current()<\/code>\u00a0\u8bb0\u5f55\u5f53\u524d await \u53d1\u751f\u7684\u6587\u4ef6\u3001\u884c\u53f7\u3001\u51fd\u6570\u540d\uff0c\u5f62\u6210\u4e00\u6761\u94fe\u3002\u8fd9\u6837\u5c31\u53ef\u4ee5\u5728\u8fd0\u884c\u65f6 dump \u51fa\u5b8c\u6574\u7684\u5f02\u6b65\u8c03\u7528\u94fe\uff1a<\/p>\n<div class=\"relative group\/copy bg-bg-000\/50 border-0.5 border-border-400 rounded-lg focus:outline-none focus-visible:ring-2 focus-visible:ring-accent-100\" tabindex=\"0\" role=\"group\" aria-label=\"Code\">\n<div class=\"sticky opacity-0 group-hover\/copy:opacity-100 group-focus-within\/copy:opacity-100 top-2 py-2 h-12 w-0 float-right\">\n<div class=\"absolute right-0 h-8 px-2 items-center inline-flex z-10\"><\/div>\n<\/div>\n<div class=\"overflow-x-auto\">\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\">asyncio callstack:\r\n  #0 tcp_echo_client at example\/echo_client.cpp:12\r\n  #1 main at example\/echo_client.cpp:20<\/pre>\n<p>&nbsp;<\/p>\n<\/div>\n<\/div>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u8fd9\u4e2a\u6280\u672f\u5728 2021 \u5e74\u9879\u76ee\u521b\u5efa\u65f6\uff0c\u5728 C++ \u5f00\u6e90\u793e\u533a\u91cc\u6781\u5c11\u6709\u4eba\u5b9e\u73b0\uff0c\u662f\u4f5c\u8005\u5bf9 C++20 \u534f\u7a0b\u673a\u5236\u6df1\u5ea6\u7406\u89e3\u540e\u7684\u539f\u521b\u5de5\u7a0b\u6280\u5de7\u3002<\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\"><strong>2. \u7ed3\u6784\u5316\u5e76\u53d1\u7684 C++ \u5b9e\u73b0<\/strong><\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\"><code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">gather()<\/code>\u3001<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">wait_for()<\/code>\u3001\u53d6\u6d88\u4f20\u64ad\u8fd9\u5957 API \u5bf9\u5e94\u7684\u662f Python asyncio \u7684\u7ed3\u6784\u5316\u5e76\u53d1\u6a21\u578b\u2014\u2014\u4e00\u7ec4\u4efb\u52a1\u8981\u4e48\u5168\u90e8\u5b8c\u6210\uff0c\u8981\u4e48\u4e00\u4e2a\u53d6\u6d88\u5e26\u52a8\u5176\u4ed6\u5168\u90e8\u53d6\u6d88\u3002\u5728 C++ \u91cc\u5b9e\u73b0\u8fd9\u4e2a\u7684\u96be\u70b9\u662f\uff1a\u53d6\u6d88\u4fe1\u53f7\u8981\u7a7f\u900f\u534f\u7a0b\u5e27\u4f20\u9012\uff0c\u4e14\u53d6\u6d88\u65f6\u8981\u6b63\u786e\u6790\u6784\u6240\u6709\u6302\u8d77\u72b6\u6001\u3002\u9879\u76ee\u901a\u8fc7\u5f02\u5e38\u673a\u5236\u5b9e\u73b0\u53d6\u6d88\u4f20\u64ad\uff0c\u8bbe\u8ba1\u662f\u5e72\u51c0\u7684\u3002<\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\"><strong>3. \u7eaf C++20\uff0c\u65e0\u5916\u90e8\u5f02\u6b65\u8fd0\u884c\u65f6\u4f9d\u8d56<\/strong><\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u4e0d\u4f9d\u8d56 libuv\u3001\u4e0d\u4f9d\u8d56 Boost.Asio \u7684\u4e8b\u4ef6\u5faa\u73af\uff0c\u5b8c\u5168\u4ece C++20 \u6807\u51c6\u5e93\u7684\u534f\u7a0b\u673a\u5236\u548c\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">epoll<\/code>\/<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">io_uring<\/code>\u00a0\u6784\u5efa\uff0c\u4fdd\u6301\u4e86\u6781\u5c0f\u7684\u5c42\u6b21\u6570\u3002\u8fd9\u5728\u540c\u7c7b\u9879\u76ee\u91cc\u4e0d\u5e38\u89c1\u2014\u2014\u5927\u591a\u6570 C++ \u534f\u7a0b\u5e93\u8981\u4e48\u57ab\u5728 ASIO \u4e4b\u4e0a\uff0c\u8981\u4e48\u57ab\u5728 libuv \u4e4b\u4e0a\u3002<\/p>\n<hr class=\"border-border-200 border-t-0.5 my-3 mx-1.5\" \/>\n<h3 class=\"text-text-100 mt-3 -mb-1 text-[1.125rem] font-bold\" dir=\"ltr\">\u6027\u80fd\u8868\u73b0<\/h3>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u57fa\u51c6\u6d4b\u8bd5\uff0810M \u8bf7\u6c42\u30011000 \u5e76\u53d1\u3001echo server\uff09\uff1a<\/p>\n<div class=\"overflow-x-auto w-full px-2 mb-6 print:overflow-x-visible\" dir=\"ltr\">\n<table class=\"min-w-full border-collapse text-sm leading-[1.7] whitespace-normal\">\n<thead class=\"text-left\">\n<tr>\n<th class=\"text-text-100 border-b-0.5 border-[hsl(var(--border-300)\/0.6)] py-2 pr-4 align-top font-bold\" scope=\"col\">\u6846\u67b6<\/th>\n<th class=\"text-text-100 border-b-0.5 border-[hsl(var(--border-300)\/0.6)] py-2 pr-4 align-top font-bold\" scope=\"col\">RPS<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\"><strong>netcan\/asyncio<\/strong><\/td>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\"><strong>164,457<\/strong><\/td>\n<\/tr>\n<tr>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">libuv<\/td>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">159,937<\/td>\n<\/tr>\n<tr>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">ASIO 1.18<\/td>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">159,322<\/td>\n<\/tr>\n<tr>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">Tokio (Rust)<\/td>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">156,852<\/td>\n<\/tr>\n<tr>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">Python asyncio+uvloop<\/td>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">100,426<\/td>\n<\/tr>\n<tr>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">Python asyncio<\/td>\n<td class=\"border-b-0.5 border-[hsl(var(--border-300)\/0.3)] py-2 pr-4 align-top\">47,393<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u9886\u5148 ASIO \u7ea6 3%\uff0c\u9886\u5148 Tokio \u7ea6 5%\u2014\u2014\u5dee\u8ddd\u5728\u540c\u7b49\u91cf\u7ea7\u5185\uff0c\u8bf4\u660e<strong>C++20 \u539f\u751f\u534f\u7a0b\u7684\u5207\u6362\u5f00\u9500\u7ea6 10 \u7eb3\u79d2<\/strong>\uff0c\u4e0e IO \u672c\u8eab\u7684\u6beb\u79d2\u7ea7\u5ef6\u8fdf\u76f8\u6bd4\u51e0\u4e4e\u53ef\u5ffd\u7565\uff0c\u4e0d\u662f\u74f6\u9888\u3002<\/p>\n<hr class=\"border-border-200 border-t-0.5 my-3 mx-1.5\" \/>\n<h3 class=\"text-text-100 mt-3 -mb-1 text-[1.125rem] font-bold\" dir=\"ltr\">\u5ba2\u89c2\u8bc4\u4ef7<\/h3>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\"><strong>\u771f\u6b63\u6709\u4ef7\u503c\u7684\u5730\u65b9\uff1a<\/strong><\/p>\n<ul class=\"[li_&amp;]:mb-0 [li_&amp;]:mt-1 [li_&amp;]:gap-1 [&amp;:not(:last-child)_ul]:pb-1 [&amp;:not(:last-child)_ol]:pb-1 list-disc flex flex-col gap-1 pl-8 mb-3 print:block print:space-y-1\" dir=\"ltr\">\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\"><code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">await_transform<\/code>\u00a0+\u00a0<code class=\"bg-text-200\/5 border border-0.5 border-border-300 text-danger-000 whitespace-pre-wrap rounded-[0.4rem] px-1 py-px text-[0.9rem]\">source_location<\/code>\u00a0\u7684\u8c03\u8bd5\u6280\u5de7\u662f\u771f\u5b9e\u7684\u6280\u672f\u521b\u65b0\uff0c\u540e\u6765\u5df2\u88ab\u5176\u4ed6\u9879\u76ee\u501f\u9274<\/li>\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\">Python asyncio API \u7684 C++ \u6620\u5c04\u662f\u4e00\u4e2a\u6e05\u6670\u4e14\u81ea\u6d3d\u7684\u8bbe\u8ba1\u54f2\u5b66\uff0c\u964d\u4f4e\u4e86\u8ba4\u77e5\u95e8\u69db<\/li>\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\">\u4ee3\u7801\u672c\u8eab\u662f\u5b66\u4e60 C++20 \u534f\u7a0b\u673a\u5236\u7684\u6781\u4f73\u53c2\u8003\uff0c\u7ed3\u6784\u6e05\u6670\uff0c\u6ca1\u6709\u8fc7\u5ea6\u62bd\u8c61<\/li>\n<\/ul>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\"><strong>\u5c40\u9650\uff1a<\/strong><\/p>\n<ul class=\"[li_&amp;]:mb-0 [li_&amp;]:mt-1 [li_&amp;]:gap-1 [&amp;:not(:last-child)_ul]:pb-1 [&amp;:not(:last-child)_ol]:pb-1 list-disc flex flex-col gap-1 pl-8 mb-3 print:block print:space-y-1\" dir=\"ltr\">\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\">\u5b9a\u4f4d\u662f\u6559\u5b66\/\u7814\u7a76\u7ea7\u9879\u76ee\uff0c\u4e0d\u662f\u751f\u4ea7\u7ea7\u5e93\u2014\u2014\u9519\u8bef\u5904\u7406\u3001\u8de8\u5e73\u53f0\u517c\u5bb9\u6027\u3001\u538b\u529b\u6d4b\u8bd5\u8986\u76d6\u90fd\u4e0d\u5b8c\u6574<\/li>\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\">\u4e0e\u5df2\u5f52\u6863\u7684\u00a0<a class=\"underline underline underline-offset-2 decoration-1 decoration-current\/40 hover:decoration-current focus:decoration-current\" href=\"https:\/\/github.com\/lewissbaker\/cppcoro\">cppcoro<\/a>\uff08Lewis Baker \u7684\u534f\u7a0b\u5e93\uff0c\u6807\u51c6\u59d4\u5458\u4f1a\u59d4\u5458\u7ea7\u522b\u7684\u4f5c\u54c1\uff09\u76f8\u6bd4\uff0c\u529f\u80fd\u5b8c\u5907\u6027\u5dee\u8ddd\u8f83\u5927<\/li>\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\">\u5355\u7ebf\u7a0b\u4e8b\u4ef6\u5faa\u73af\u6a21\u578b\u5bf9\u591a\u6838\u5229\u7528\u6ca1\u6709\u8bbe\u8ba1<\/li>\n<\/ul>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\"><strong>\u4e0e\u524d\u4f5c zhanglix\/asyncio \u7684\u672c\u8d28\u533a\u522b\uff1a<\/strong>\u00a0zhanglix \u7684\u7248\u672c\u7528\u7684\u662f 2017 \u5e74 LLVM \u7684\u5b9e\u9a8c\u6027\u534f\u7a0b TS\uff0c\u662f\u65e9\u671f\u63a2\u7d22\uff1bnetcan \u7684\u7248\u672c\u662f\u5b8c\u6574 C++20 \u6807\u51c6\u7279\u6027\uff0c\u662f\u751f\u4ea7\u8bed\u8a00\u7684\u6b63\u5f0f\u7279\u6027\u5b9e\u73b0\u2014\u2014\u4e24\u8005\u867d\u7136\u540d\u5b57\u76f8\u4f3c\uff0c\u6280\u672f\u8def\u5f84\u5b8c\u5168\u4e0d\u540c\u3002<\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">\u603b\u7ed3\uff1a\u8fd9\u662f\u4e00\u4e2a\u6280\u672f\u6df1\u5ea6\u624e\u5b9e\u3001\u6709\u6e05\u6670\u8bbe\u8ba1\u54f2\u5b66\u3001\u5e26\u6709\u4e00\u4e24\u4e2a\u771f\u6b63\u539f\u521b\u6280\u5de7\u7684\u9ad8\u8d28\u91cf\u4e2a\u4eba\u9879\u76ee\u3002\u5728 C++20 \u534f\u7a0b\u751f\u6001\u8fd8\u5f88\u8352\u829c\u7684 2021-2022 \u5e74\uff0c\u5b83\u662f\u5c11\u6570\u628a&#8221;\u53ef\u7528\u7684\u5f02\u6b65\u8fd0\u884c\u65f6&#8221;\u8fd9\u4ef6\u4e8b\u8ba4\u771f\u505a\u51fa\u6765\u7684 C++ \u5f00\u6e90\u4f5c\u54c1\u4e4b\u4e00\u3002<\/p>\n<p class=\"font-claude-response-body break-words whitespace-normal\" dir=\"ltr\">Sources:<\/p>\n<ul class=\"[li_&amp;]:mb-0 [li_&amp;]:mt-1 [li_&amp;]:gap-1 [&amp;:not(:last-child)_ul]:pb-1 [&amp;:not(:last-child)_ol]:pb-1 list-disc flex flex-col gap-1 pl-8 mb-3 print:block print:space-y-1\" dir=\"ltr\">\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\"><a class=\"underline underline underline-offset-2 decoration-1 decoration-current\/40 hover:decoration-current focus:decoration-current\" href=\"https:\/\/github.com\/netcan\/asyncio\">GitHub &#8211; netcan\/asyncio<\/a><\/li>\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\"><a class=\"underline underline underline-offset-2 decoration-1 decoration-current\/40 hover:decoration-current focus:decoration-current\" href=\"https:\/\/netcan.github.io\/2021\/12\/04\/C-20%E5%8D%8F%E7%A8%8B%E7%89%B9%E6%80%A7%E6%80%A7%E8%83%BD%E6%B5%8B%E8%AF%95\/\">C++20 \u534f\u7a0b\u6027\u80fd\u6d4b\u8bd5 &#8211; Netcan<\/a><\/li>\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\"><a class=\"underline underline underline-offset-2 decoration-1 decoration-current\/40 hover:decoration-current focus:decoration-current\" href=\"https:\/\/github.com\/netcan\/asyncio\/blob\/master\/docs\/benchmark.md\">asyncio benchmark.md<\/a><\/li>\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\"><a class=\"underline underline underline-offset-2 decoration-1 decoration-current\/40 hover:decoration-current focus:decoration-current\" href=\"https:\/\/www.jeremyong.com\/cpp\/2021\/01\/04\/cpp20-coroutines-a-minimal-async-framework\/\">C++20 Coroutines: sketching a minimal async framework<\/a><\/li>\n<li class=\"font-claude-response-body whitespace-normal break-words pl-2\"><a class=\"underline underline underline-offset-2 decoration-1 decoration-current\/40 hover:decoration-current focus:decoration-current\" href=\"https:\/\/github.com\/Hackerl\/asyncio\">GitHub &#8211; Hackerl\/asyncio: C++23 coroutine network framework<\/a><\/li>\n<\/ul>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u8fd9\u662f\u4e2a\u5f88\u503c\u5f97\u6df1\u6316\u7684\u9879\u76ee\u3002\u7efc\u5408\u6765\u770b\uff0c\u5b83\u7684\u539f<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"colormag_page_container_layout":"default_layout","colormag_page_sidebar_layout":"default_layout","footnotes":""},"categories":[24],"tags":[],"class_list":["post-7487","post","type-post","status-publish","format-standard","hentry","category-value_docs"],"_links":{"self":[{"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/posts\/7487","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/comments?post=7487"}],"version-history":[{"count":1,"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/posts\/7487\/revisions"}],"predecessor-version":[{"id":7488,"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/posts\/7487\/revisions\/7488"}],"wp:attachment":[{"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/media?parent=7487"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/categories?post=7487"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/i007.cc\/wordpress\/wp-json\/wp\/v2\/tags?post=7487"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}