\doxysection{meta.\+c}
\hypertarget{meta_8c_source}{}\label{meta_8c_source}\index{workspace/post-\/scarcity/src/ops/meta.c@{workspace/post-\/scarcity/src/ops/meta.c}}
\mbox{\hyperlink{meta_8c}{Go to the documentation of this file.}}
\begin{DoxyCode}{0}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00001}00001\ \textcolor{comment}{/*}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00002}00002\ \textcolor{comment}{\ *\ meta.c}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00003}00003\ \textcolor{comment}{\ *}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00004}00004\ \textcolor{comment}{\ *\ Get\ metadata\ from\ a\ cell\ which\ has\ it.}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00005}00005\ \textcolor{comment}{\ *}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00006}00006\ \textcolor{comment}{\ *\ (c)\ 2019\ Simon\ Brooke\ <simon@journeyman.cc>}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00007}00007\ \textcolor{comment}{\ *\ Licensed\ under\ GPL\ version\ 2.0,\ or,\ at\ your\ option,\ any\ later\ version.}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00008}00008\ \textcolor{comment}{\ */}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00009}00009\ }
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00010}00010\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{conspage_8h}{memory/conspage.h}}"{}}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00011}00011\ \textcolor{preprocessor}{\#include\ "{}\mbox{\hyperlink{debug_8h}{debug.h}}"{}}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00012}00012\ \textcolor{comment}{}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00013}00013\ \textcolor{comment}{/**}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00014}00014\ \textcolor{comment}{\ *\ Function:\ get\ metadata\ describing\ my\ first\ argument.}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00015}00015\ \textcolor{comment}{\ *}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00016}00016\ \textcolor{comment}{\ *\ *\ (metadata\ any)}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00017}00017\ \textcolor{comment}{\ *}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00018}00018\ \textcolor{comment}{\ *\ @return\ a\ pointer\ to\ the\ metadata\ of\ my\ first\ argument,\ or\ nil\ if\ none.}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00019}00019\ \textcolor{comment}{\ */}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00020}\mbox{\hyperlink{meta_8c_a2a14145b7c3d56a91b58c9ac8d044f14}{00020}}\ \textcolor{keyword}{struct\ }\mbox{\hyperlink{consspaceobject_8h_structcons__pointer}{cons\_pointer}}\ \mbox{\hyperlink{meta_8c_a2a14145b7c3d56a91b58c9ac8d044f14}{lisp\_metadata}}(\ struct\ \mbox{\hyperlink{consspaceobject_8h_structstack__frame}{stack\_frame}}\ *frame,}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00021}00021\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keyword}{struct\ }\mbox{\hyperlink{consspaceobject_8h_structcons__pointer}{cons\_pointer}}\ frame\_pointer,}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00022}00022\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ struct\ \mbox{\hyperlink{consspaceobject_8h_structcons__pointer}{cons\_pointer}}\ env\ )\ \{}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00023}00023\ \ \ \ \ \mbox{\hyperlink{debug_8c_ad55e4f61e076944d705d98b5314c5181}{debug\_print}}(\ L\textcolor{stringliteral}{"{}lisp\_metadata:\ entered\(\backslash\)n"{}},\ \mbox{\hyperlink{debug_8h_afac31e745564644b8a5c242dc195844c}{DEBUG\_EVAL}}\ );}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00024}00024\ \ \ \ \ \mbox{\hyperlink{debug_8c_aa0ffa929ddbce890ce4f81264a211233}{debug\_dump\_object}}(\ frame-\/>arg[0],\ \mbox{\hyperlink{debug_8h_afac31e745564644b8a5c242dc195844c}{DEBUG\_EVAL}}\ );}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00025}00025\ \ \ \ \ \textcolor{keyword}{struct\ }\mbox{\hyperlink{consspaceobject_8h_structcons__pointer}{cons\_pointer}}\ result\ =\ \mbox{\hyperlink{consspaceobject_8h_a263efce0e5cda1d387a1a43f94715445}{NIL}};}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00026}00026\ \ \ \ \ \textcolor{keyword}{struct\ }\mbox{\hyperlink{consspaceobject_8h_structcons__space__object}{cons\_space\_object}}\ cell\ =\ \mbox{\hyperlink{consspaceobject_8h_af31e1da9438d7ae4410864ecc901b131}{pointer2cell}}(\ frame-\/>arg[0]\ );}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00027}00027\ }
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00028}00028\ \ \ \ \ \textcolor{keywordflow}{switch}\ (\ cell.\mbox{\hyperlink{consspaceobject_8h_a21cb645ce4ae20308447dcd59534bf38}{tag}}.value\ )\ \{}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00029}00029\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{case}\ \mbox{\hyperlink{consspaceobject_8h_a291e48d2612ab2b3b86fa677d13824b3}{FUNCTIONTV}}:}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00030}00030\ \ \ \ \ \ \ \ \ \ \ \ \ result\ =\ cell.\mbox{\hyperlink{consspaceobject_8h_a259b3afe36776f8ba8498fdf95904f25}{payload}}.function.meta;}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00031}00031\ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00032}00032\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{case}\ \mbox{\hyperlink{consspaceobject_8h_a0569cc92977f62ba26b81c00e661b973}{SPECIALTV}}:}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00033}00033\ \ \ \ \ \ \ \ \ \ \ \ \ result\ =\ cell.\mbox{\hyperlink{consspaceobject_8h_a259b3afe36776f8ba8498fdf95904f25}{payload}}.special.meta;}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00034}00034\ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00035}00035\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{case}\ \mbox{\hyperlink{consspaceobject_8h_adaf34dffde713283cf269225ee0343a8}{READTV}}:}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00036}00036\ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{case}\ \mbox{\hyperlink{consspaceobject_8h_ad677447e4a46d52d256d0fe671e2d663}{WRITETV}}:}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00037}00037\ \ \ \ \ \ \ \ \ \ \ \ \ result\ =\ cell.\mbox{\hyperlink{consspaceobject_8h_a259b3afe36776f8ba8498fdf95904f25}{payload}}.stream.meta;}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00038}00038\ \ \ \ \ \ \ \ \ \ \ \ \ \textcolor{keywordflow}{break};}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00039}00039\ \ \ \ \ \}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00040}00040\ }
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00041}00041\ \ \ \ \ \textcolor{keywordflow}{return}\ \mbox{\hyperlink{consspaceobject_8h_afff9c83c8c250837b5737c11e21cc4ca}{make\_cons}}(\ \mbox{\hyperlink{consspaceobject_8h_afff9c83c8c250837b5737c11e21cc4ca}{make\_cons}}(\ \mbox{\hyperlink{consspaceobject_8h_a36a68d265999acf02988326ec4c53fc2}{c\_string\_to\_lisp\_keyword}}(\ L\textcolor{stringliteral}{"{}type"{}}\ ),}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00042}00042\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \mbox{\hyperlink{consspaceobject_8h_ad6da5748c65be5613d86664948ecc5ab}{c\_type}}(\ frame-\/>arg[0]\ )\ ),\ result\ );}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00043}00043\ }
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00044}00044\ \textcolor{comment}{//\ \ return\ result;}}
\DoxyCodeLine{\Hypertarget{meta_8c_source_l00045}00045\ \}}

\end{DoxyCode}
