Files
hustoj/web/cppreference-zh/chmhelp/cpp-coroutine-coroutine_handle-address.html
2025-08-01 12:57:54 +08:00

59 lines
3.3 KiB
HTML

<!DOCTYPE html>
<html lang="zh" dir="ltr" class="client-nojs" xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh">
<head><meta http-equiv="x-ua-compatible" content="ie=edge">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>std::coroutine_handle&lt;Promise&gt;::address</title>
<link rel="stylesheet" href="ext.css" />
<link rel="stylesheet" href="site_modules.css" />
</head>
<body class="mediawiki ltr sitedir-ltr ns-0 ns-subject page-cpp_coroutine_coroutine_handle_address skin-cppreference2 action-view cpp-navbar">
<div id="cpp-content-base">
<div id="content"><a id="top"></a>
<h1 id="firstHeading" class="firstHeading"><span style="font-size:0.7em; line-height:130%">std::coroutine_handle&lt;Promise&gt;::</span>address</h1>
<div id="bodyContent">
<div id="contentSub"><span class="subpages">&lt; <a href="cpp.html">cpp</a>&lrm; | <a href="cpp-coroutine.html">coroutine</a>&lrm; | <a href="cpp-coroutine-coroutine_handle.html">coroutine handle</a></span></div>
<div id="mw-content-text" lang="zh" dir="ltr" class="mw-content-ltr" xml:lang="zh">
<table class="t-dcl-begin">
<tbody>
<tr class="t-dcl t-since-cxx20">
<td>
<div><span class="mw-geshi cpp source-cpp"><span class="kw4">constexpr</span> <span class="kw4">void</span><span class="sy2">*</span> address<span class="br0">(</span><span class="br0">)</span> <span class="kw4">const</span> <span class="kw1">noexcept</span><span class="sy4">;</span></span></div>
</td>
<td class="t-dcl-nopad"></td>
<td><span class="t-mark-rev t-since-cxx20">(C++20 &#36215;)</span></td>
</tr>
<tr class="t-dcl-sep">
<td></td>
<td></td>
<td></td>
</tr>
</tbody>
</table>
<p>&#36820;&#22238; <code>coroutine_handle</code> &#30340;&#24213;&#23618;&#22320;&#22336;&#12290;&#36820;&#22238;&#20540;&#20026;&#38750;&#31354;&#24403;&#19988;&#20165;&#24403; <code>coroutine_handle</code> &#30340;&#24403;&#21069;&#20540;&#20174;&#21327;&#31243;&#30340;&#25215;&#35834;&#23545;&#35937;&#33719;&#24471;&#12290;</p>
<h3><span class="mw-headline" id=".E5.8F.82.E6.95.B0">&#21442;&#25968;</span></h3>
<p>&#65288;&#26080;&#65289;</p>
<h3><span class="mw-headline" id=".E8.BF.94.E5.9B.9E.E5.80.BC">&#36820;&#22238;&#20540;</span></h3>
<p>&#24213;&#23618;&#22320;&#22336;&#12290;</p>
<h3><span class="mw-headline" id=".E6.B3.A8.E8.A7.A3">&#27880;&#35299;</span></h3>
<p>&#36820;&#22238;&#20540;&#23545;&#29305;&#21270; <span class="t-lc">std::noop_coroutine_handle</span> &#22987;&#32456;&#20026;&#38750;&#31354;&#65292;&#22240;&#20026;&#19981;&#33021;&#21019;&#24314; <code>std::noop_coroutine_handle</code> &#32780;&#19981;&#20351;&#23427;&#25351;&#20195;&#26080;&#25805;&#20316;&#21327;&#31243;&#12290;</p>
<h3><span class="mw-headline" id=".E5.8F.82.E9.98.85">&#21442;&#38405;</span></h3>
<table class="t-dsc-begin">
<tr class="t-dsc">
<td>
<div class="t-dsc-member-div">
<div><a href="cpp-coroutine-coroutine_handle-from_address.html"><span class="t-lines"><span>from_address</span></span></a></div>
<div><span class="t-lines"><span><span class="t-cmark">[&#38745;&#24577;]</span> <span class="t-mark-rev t-since-cxx20">(C++20)</span></span></span></div>
</div>
</td>
<td>&#20174;&#25351;&#38024;&#23548;&#20837;&#21327;&#31243;<br />
<span class="t-mark">(&#20844;&#24320;&#38745;&#24577;&#25104;&#21592;&#20989;&#25968;)</span></td>
</tr>
</table>
</div>
<div class="visualClear"></div>
</div>
</div>
</div>
</body>
</html>