[#bsl-stop_source-get_token]
= xref:bsl.adoc[bsl]::xref:bsl/stop_source.adoc[stop&lowbar;source]::get&lowbar;token
:relfileprefix: ../../
:mrdocs:

Return a `stop&lowbar;token` that refers to the stop state (or lack thereof) that `&ast;this` refers to&period;

== Synopsis

Declared in `&lt;bslstl&lowbar;stoptoken&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
&lsqb;&lsqb;nodiscard&rsqb;&rsqb;
xref:bsl/stop_token.adoc[stop&lowbar;token]
get&lowbar;token() const noexcept;
----

== Return Value

`stop&lowbar;token` referring to the same stop state as `&ast;this`

[NOTE]
====
The return value https://en.cppreference.com/cpp/language/attributes/nodiscard[should not be discarded^].
====

[.small]#Created with https://www.mrdocs.com[MrDocs]#
