107 lines
29 KiB
HTML
107 lines
29 KiB
HTML
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Helper methods for `Result`s."><title>ResultExt in rancor - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-6b053e98.ttf.woff2,FiraSans-Regular-0fe48ade.woff2,FiraSans-Medium-e1aa3f0a.woff2,SourceCodePro-Regular-8badfe75.ttf.woff2,SourceCodePro-Semibold-aa29a496.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2" crossorigin href="../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../static.files/normalize-9960930a.css"><link rel="stylesheet" href="../static.files/rustdoc-42caa33d.css"><meta name="rustdoc-vars" data-root-path="../" data-static-root-path="../static.files/" data-current-crate="rancor" data-themes="" data-resource-suffix="" data-rustdoc-version="1.84.0 (9fc6b4312 2025-01-07)" data-channel="1.84.0" data-search-js="search-92e6798f.js" data-settings-js="settings-0f613d39.js" ><script src="../static.files/storage-59e33391.js"></script><script defer src="sidebar-items.js"></script><script defer src="../static.files/main-5f194d8c.js"></script><noscript><link rel="stylesheet" href="../static.files/noscript-893ab5e7.css"></noscript><link rel="alternate icon" type="image/png" href="../static.files/favicon-32x32-6580c154.png"><link rel="icon" type="image/svg+xml" href="../static.files/favicon-044be391.svg"></head><body class="rustdoc trait"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><nav class="mobile-topbar"><button class="sidebar-menu-toggle" title="show sidebar"></button></nav><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../rancor/index.html">rancor</a><span class="version">0.1.0</span></h2></div><div class="sidebar-elems"><section id="rustdoc-toc"><h2 class="location"><a href="#">Result<wbr>Ext</a></h2><h3><a href="#required-methods">Required Methods</a></h3><ul class="block"><li><a href="#tymethod.always_ok" title="always_ok">always_ok</a></li><li><a href="#tymethod.into_error" title="into_error">into_error</a></li><li><a href="#tymethod.into_trace" title="into_trace">into_trace</a></li><li><a href="#tymethod.into_with_trace" title="into_with_trace">into_with_trace</a></li><li><a href="#tymethod.trace" title="trace">trace</a></li><li><a href="#tymethod.with_trace" title="with_trace">with_trace</a></li></ul><h3><a href="#foreign-impls">Implementations on Foreign Types</a></h3><ul class="block"><li><a href="#impl-ResultExt%3CT,+E%3E-for-Result%3CT,+E%3E" title="Result<T, E>">Result<T, E></a></li></ul><h3><a href="#dyn-compatibility">Dyn Compatibility</a></h3><h3><a href="#implementors">Implementors</a></h3></section><div id="rustdoc-modnav"><h2 class="in-crate"><a href="index.html">In crate rancor</a></h2></div></div></nav><div class="sidebar-resizer"></div><main><div class="width-limiter"><rustdoc-search></rustdoc-search><section id="main-content" class="content"><div class="main-heading"><span class="rustdoc-breadcrumbs"><a href="index.html">rancor</a></span><h1>Trait <span class="trait">ResultExt</span><button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"><a class="src" href="../src/rancor/lib.rs.html#288-398">Source</a> </span></div><pre class="rust item-decl"><code>pub trait ResultExt<T, E> {
|
|
// Required methods
|
|
fn <a href="#tymethod.into_error" class="fn">into_error</a><U>(self) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U>
|
|
<span class="where">where U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static</span>;
|
|
<span class="item-spacer"></span> fn <a href="#tymethod.into_trace" class="fn">into_trace</a><U, R>(self, trace: R) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U>
|
|
<span class="where">where U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static</span>;
|
|
<span class="item-spacer"></span> fn <a href="#tymethod.into_with_trace" class="fn">into_with_trace</a><U, R, F>(self, f: F) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U>
|
|
<span class="where">where U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
F: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>() -> R,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static</span>;
|
|
<span class="item-spacer"></span> fn <a href="#tymethod.trace" class="fn">trace</a><R>(self, trace: R) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, E>
|
|
<span class="where">where R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
E: <a class="trait" href="trait.Trace.html" title="trait rancor::Trace">Trace</a></span>;
|
|
<span class="item-spacer"></span> fn <a href="#tymethod.with_trace" class="fn">with_trace</a><R, F>(self, f: F) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, E>
|
|
<span class="where">where R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
F: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>() -> R,
|
|
E: <a class="trait" href="trait.Trace.html" title="trait rancor::Trace">Trace</a></span>;
|
|
<span class="item-spacer"></span> fn <a href="#tymethod.always_ok" class="fn">always_ok</a>(self) -> T
|
|
<span class="where">where E: <a class="trait" href="trait.Never.html" title="trait rancor::Never">Never</a></span>;
|
|
}</code></pre><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Helper methods for <code>Result</code>s.</p>
|
|
</div></details><h2 id="required-methods" class="section-header">Required Methods<a href="#required-methods" class="anchor">§</a></h2><div class="methods"><details class="toggle method-toggle" open><summary><section id="tymethod.into_error" class="method"><a class="src rightside" href="../src/rancor/lib.rs.html#298-301">Source</a><h4 class="code-header">fn <a href="#tymethod.into_error" class="fn">into_error</a><U>(self) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U><div class="where">where
|
|
U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,</div></h4></section></summary><div class="docblock"><p>Returns a <code>Result</code> with this error type converted to <code>U</code>.</p>
|
|
<h5 id="example"><a class="doc-anchor" href="#example">§</a>Example</h5>
|
|
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use </span>rancor::{Failure, ResultExt <span class="kw">as _</span>};
|
|
|
|
<span class="kw">let </span>result = <span class="string">"1_000"</span>.parse::<i32>().into_error::<Failure>();</code></pre></div>
|
|
</div></details><details class="toggle method-toggle" open><summary><section id="tymethod.into_trace" class="method"><a class="src rightside" href="../src/rancor/lib.rs.html#315-319">Source</a><h4 class="code-header">fn <a href="#tymethod.into_trace" class="fn">into_trace</a><U, R>(self, trace: R) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U><div class="where">where
|
|
U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,</div></h4></section></summary><div class="docblock"><p>Returns a <code>Result</code> with this error type converted to <code>U</code> and with an
|
|
additional <code>trace</code> message added.</p>
|
|
<h5 id="example-1"><a class="doc-anchor" href="#example-1">§</a>Example</h5>
|
|
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use </span>rancor::{BoxedError, ResultExt <span class="kw">as _</span>};
|
|
|
|
<span class="kw">let </span>result = <span class="string">"1_000"
|
|
</span>.parse::<i32>()
|
|
.into_trace::<BoxedError, <span class="kw">_</span>>(<span class="string">"while parsing 1_000"</span>);</code></pre></div>
|
|
</div></details><details class="toggle method-toggle" open><summary><section id="tymethod.into_with_trace" class="method"><a class="src rightside" href="../src/rancor/lib.rs.html#338-343">Source</a><h4 class="code-header">fn <a href="#tymethod.into_with_trace" class="fn">into_with_trace</a><U, R, F>(self, f: F) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U><div class="where">where
|
|
U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
F: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>() -> R,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,</div></h4></section></summary><div class="docblock"><p>Returns a <code>Result</code> with this error type converted to <code>U</code> and with an
|
|
additional trace message added by evaluating the given function <code>f</code>. The
|
|
function is evaluated only if an error occurred.</p>
|
|
<h5 id="example-2"><a class="doc-anchor" href="#example-2">§</a>Example</h5>
|
|
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use </span>rancor::{BoxedError, ResultExt <span class="kw">as _</span>};
|
|
|
|
<span class="kw">let </span>input = <span class="string">"1_000"</span>;
|
|
<span class="kw">let </span>result =
|
|
input
|
|
.parse::<i32>()
|
|
.into_with_trace::<BoxedError, <span class="kw">_</span>, <span class="kw">_</span>>(|| {
|
|
<span class="macro">format!</span>(<span class="string">"while parsing {input}"</span>)
|
|
});</code></pre></div>
|
|
</div></details><details class="toggle method-toggle" open><summary><section id="tymethod.trace" class="method"><a class="src rightside" href="../src/rancor/lib.rs.html#357-360">Source</a><h4 class="code-header">fn <a href="#tymethod.trace" class="fn">trace</a><R>(self, trace: R) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, E><div class="where">where
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
E: <a class="trait" href="trait.Trace.html" title="trait rancor::Trace">Trace</a>,</div></h4></section></summary><div class="docblock"><p>Adds an additional <code>trace</code> message to the error value of this type.</p>
|
|
<h5 id="example-3"><a class="doc-anchor" href="#example-3">§</a>Example</h5>
|
|
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use </span>rancor::{BoxedError, ResultExt <span class="kw">as _</span>};
|
|
|
|
<span class="kw">let </span>result = <span class="string">"1_000"
|
|
</span>.parse::<i32>()
|
|
.into_error::<BoxedError>()
|
|
.trace(<span class="string">"while parsing 1_000"</span>);</code></pre></div>
|
|
</div></details><details class="toggle method-toggle" open><summary><section id="tymethod.with_trace" class="method"><a class="src rightside" href="../src/rancor/lib.rs.html#377-381">Source</a><h4 class="code-header">fn <a href="#tymethod.with_trace" class="fn">with_trace</a><R, F>(self, f: F) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, E><div class="where">where
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
F: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>() -> R,
|
|
E: <a class="trait" href="trait.Trace.html" title="trait rancor::Trace">Trace</a>,</div></h4></section></summary><div class="docblock"><p>Adds an additional trace message to the error value of this type by
|
|
evaluating the given function <code>f</code>. The function is evaluated only if an
|
|
error occurred.</p>
|
|
<h5 id="example-4"><a class="doc-anchor" href="#example-4">§</a>Example</h5>
|
|
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use </span>rancor::{BoxedError, ResultExt <span class="kw">as _</span>};
|
|
|
|
<span class="kw">let </span>input = <span class="string">"1_000"</span>;
|
|
<span class="kw">let </span>result = input
|
|
.parse::<i32>()
|
|
.into_error::<BoxedError>()
|
|
.with_trace(|| <span class="macro">format!</span>(<span class="string">"while parsing {input}"</span>));</code></pre></div>
|
|
</div></details><details class="toggle method-toggle" open><summary><section id="tymethod.always_ok" class="method"><a class="src rightside" href="../src/rancor/lib.rs.html#395-397">Source</a><h4 class="code-header">fn <a href="#tymethod.always_ok" class="fn">always_ok</a>(self) -> T<div class="where">where
|
|
E: <a class="trait" href="trait.Never.html" title="trait rancor::Never">Never</a>,</div></h4></section></summary><div class="docblock"><p>Safely unwraps a result that is always <code>Ok</code>.</p>
|
|
<p>In order to call this method, the error type of this <code>Result</code> must be a
|
|
<a href="trait.Never.html" title="trait rancor::Never"><code>Never</code></a> type.</p>
|
|
<h5 id="example-5"><a class="doc-anchor" href="#example-5">§</a>Example</h5>
|
|
<div class="example-wrap"><pre class="rust rust-example-rendered"><code><span class="kw">use </span>rancor::{Infallible, ResultExt};
|
|
|
|
<span class="kw">let </span>inner = <span class="prelude-val">Ok</span>::<i32, Infallible>(<span class="number">10</span>).always_ok();</code></pre></div>
|
|
</div></details></div><h2 id="dyn-compatibility" class="section-header">Dyn Compatibility<a href="#dyn-compatibility" class="anchor">§</a></h2><div class="dyn-compatibility-info"><p>This trait is <b>not</b> <a href="https://doc.rust-lang.org/1.84.0/reference/items/traits.html#object-safety">dyn compatible</a>.</p><p><i>In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.</i></p></div><h2 id="foreign-impls" class="section-header">Implementations on Foreign Types<a href="#foreign-impls" class="anchor">§</a></h2><details class="toggle implementors-toggle"><summary><section id="impl-ResultExt%3CT,+E%3E-for-Result%3CT,+E%3E" class="impl"><a class="src rightside" href="../src/rancor/lib.rs.html#400-469">Source</a><a href="#impl-ResultExt%3CT,+E%3E-for-Result%3CT,+E%3E" class="anchor">§</a><h3 class="code-header">impl<T, E> <a class="trait" href="trait.ResultExt.html" title="trait rancor::ResultExt">ResultExt</a><T, E> for <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, E></h3></section></summary><div class="impl-items"><section id="method.into_error" class="method trait-impl"><a class="src rightside" href="../src/rancor/lib.rs.html#401-410">Source</a><a href="#method.into_error" class="anchor">§</a><h4 class="code-header">fn <a href="#tymethod.into_error" class="fn">into_error</a><U>(self) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U><div class="where">where
|
|
U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,</div></h4></section><section id="method.into_trace" class="method trait-impl"><a class="src rightside" href="../src/rancor/lib.rs.html#412-422">Source</a><a href="#method.into_trace" class="anchor">§</a><h4 class="code-header">fn <a href="#tymethod.into_trace" class="fn">into_trace</a><U, R>(self, trace: R) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U><div class="where">where
|
|
U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,</div></h4></section><section id="method.into_with_trace" class="method trait-impl"><a class="src rightside" href="../src/rancor/lib.rs.html#424-435">Source</a><a href="#method.into_with_trace" class="anchor">§</a><h4 class="code-header">fn <a href="#tymethod.into_with_trace" class="fn">into_with_trace</a><U, R, F>(self, f: F) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, U><div class="where">where
|
|
U: <a class="trait" href="trait.Source.html" title="trait rancor::Source">Source</a>,
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
F: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>() -> R,
|
|
E: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/error/trait.Error.html" title="trait core::error::Error">Error</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,</div></h4></section><section id="method.trace" class="method trait-impl"><a class="src rightside" href="../src/rancor/lib.rs.html#437-446">Source</a><a href="#method.trace" class="anchor">§</a><h4 class="code-header">fn <a href="#tymethod.trace" class="fn">trace</a><R>(self, trace: R) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, E><div class="where">where
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
E: <a class="trait" href="trait.Trace.html" title="trait rancor::Trace">Trace</a>,</div></h4></section><section id="method.with_trace" class="method trait-impl"><a class="src rightside" href="../src/rancor/lib.rs.html#448-458">Source</a><a href="#method.with_trace" class="anchor">§</a><h4 class="code-header">fn <a href="#tymethod.with_trace" class="fn">with_trace</a><R, F>(self, f: F) -> <a class="enum" href="https://doc.rust-lang.org/1.84.0/core/result/enum.Result.html" title="enum core::result::Result">Result</a><T, E><div class="where">where
|
|
R: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Debug.html" title="trait core::fmt::Debug">Debug</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/fmt/trait.Display.html" title="trait core::fmt::Display">Display</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Send.html" title="trait core::marker::Send">Send</a> + <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/marker/trait.Sync.html" title="trait core::marker::Sync">Sync</a> + 'static,
|
|
F: <a class="trait" href="https://doc.rust-lang.org/1.84.0/core/ops/function/trait.FnOnce.html" title="trait core::ops::function::FnOnce">FnOnce</a>() -> R,
|
|
E: <a class="trait" href="trait.Trace.html" title="trait rancor::Trace">Trace</a>,</div></h4></section><section id="method.always_ok" class="method trait-impl"><a class="src rightside" href="../src/rancor/lib.rs.html#460-468">Source</a><a href="#method.always_ok" class="anchor">§</a><h4 class="code-header">fn <a href="#tymethod.always_ok" class="fn">always_ok</a>(self) -> T<div class="where">where
|
|
E: <a class="trait" href="trait.Never.html" title="trait rancor::Never">Never</a>,</div></h4></section></div></details><h2 id="implementors" class="section-header">Implementors<a href="#implementors" class="anchor">§</a></h2><div id="implementors-list"></div><script src="../trait.impl/rancor/trait.ResultExt.js" data-ignore-extern-crates="core" async></script></section></div></main></body></html> |