[#absl-StatusOr-2constructor-0a]
= xref:absl.adoc[absl]::xref:absl/StatusOr.adoc[StatusOr]::StatusOr
:relfileprefix: ../../
:mrdocs:

Constructs a new `StatusOr` with an unknown status&period;

== Synopsis

Declared in `&lt;absl&sol;status&sol;statusor&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
explicit
StatusOr();
----

== Description

Constructs a new `absl&colon;&colon;StatusOr` with an `absl&colon;&colon;StatusCode&colon;&colon;kUnknown` status&period; This constructor is marked &apos;explicit&apos; to prevent usages in return values such as &apos;return &lcub;&rcub;&semi;&apos;, under the misconception that `absl&colon;&colon;StatusOr&lt;std&colon;&colon;vector&lt;int&gt;&gt;` will be initialized with an empty vector, instead of an `absl&colon;&colon;StatusCode&colon;&colon;kUnknown` error code&period;


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