[#mrdocs-dereferenceable]
= xref:mrdocs.adoc[mrdocs]::dereferenceable
:relfileprefix: ../
:mrdocs:

Determine if a type is dereferenceable

== Synopsis

Declared in `&lt;mrdocs&sol;Support&sol;Concepts&period;hpp&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class T&gt;
concept dereferenceable = requires(T const&amp; t)
&lcub;
    &lcub; static&lowbar;cast&lt;bool&gt;(t) &rcub;&semi;
    &lcub; &ast;t &rcub;&semi;
&rcub;;
----

== Description

This concept checks if a type can be dereferenced to a value it represents and converted to a boolean value that represents if the object is in a valid state&period;

Examples of such types are std&colon;&colon;optional, std&colon;&colon;unique&lowbar;ptr, std&colon;&colon;shared&lowbar;ptr, Polymorphic, pointers, etc&period;


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