.Dd March 12, 2020 .Os libzt 0.3.1 .Dt ZT_CMP_PTR 3 PRM .Sh NAME .Nm ZT_CMP_PTR , .Nm zt_cmp_int .Nd construct a claim of a relation between two pointers .Sh SYNOPSIS .In zt.h .Bd -literal #define ZT_CMP_PTR(left, rel, right) \\ zt_cmp_ptr( \\ ZT_CURRENT_LOCATION(), \\ zt_pack_pointer((left), (#left)), \\ zt_pack_string((#rel), (#rel)), \\ zt_pack_pointer((right), (#right))) .Ed .Ft zt_claim .Fo zt_cmp_ptr .Fa "zt_location location" .Fa "zt_value left" .Fa "zt_value rel" .Fa "zt_value right" .Fc .Sh DESCRIPTION .Fn zt_cmp_ptr constructs a claim of a relation between two integers. It should be used through the macro .Fn ZT_CMP_PTR which passes source code location and packs arguments. .Pp The relation must be either .Em == , or .Em != .Sh IMPLEMENTATION NOTES .Fn ZT_CMP_PTR evaluates .Em left and .Em right exactly once. .Sh RETURN VALUES Both the macro and the function return a claim structure with the right attributes set. The returned claim is usually passed to .Fn zt_check or to .Fn zt_assert . .Sh SEE ALSO .Xr ZT_CMP_BOOL 3 , .Xr ZT_CMP_CHAR 3 , .Xr ZT_CMP_CSTR 3 , .Xr ZT_CMP_PTR 3 , .Xr ZT_CMP_UINT 3 , .Xr ZT_FALSE 3 , .Xr ZT_NOT_NULL 3 , .Xr ZT_NULL 3 , .Xr ZT_TRUE 3 , .Xr zt_check 3 , .Sh HISTORY The .Fn ZT_CMP_PTR macro and the .Fn zt_cmp_ptr function first appeared in libzt 0.3 .Sh AUTHORS .An "Zygmunt Krynicki" Aq Mt me@zygoon.pl