Scroll to navigation

PMIX_REGEX2_CONSTRUCT(3) OpenPMIx PMIX_REGEX2_CONSTRUCT(3)

PMIx_Regex2_construct — Initialize a caller-provided pmix_regex2_t(5) <#man5-pmix-regex2-t> structure.

SYNOPSIS

#include <pmix.h>
void PMIx_Regex2_construct(pmix_regex2_t *d);


Python Syntax

No Python equivalent

INPUT PARAMETERS

•
d: Pointer to the pmix_regex2_t structure to be initialized. The storage for the structure itself must already exist — it is supplied by the caller (typically declared on the stack or embedded within another object).

DESCRIPTION

Initialize the fields of a pmix_regex2_t that the caller has already allocated. A pmix_regex2_t describes a PMIx encoded regular expression and carries three fields:

  • type — a colon-delimited identifier of the encoding method (for example "pmix" or "blob");
  • bytes — the encoded representation, which may not be NULL-terminated;
  • len — the number of bytes in the encoded representation.

Construction sets the type and bytes pointers to NULL and len to zero. No heap memory is allocated.

Because PMIx_Regex2_construct operates on caller-provided storage, it must be paired with PMIx_Regex2_destruct(3) <#man3-pmix-regex2-destruct> to release any payload the structure subsequently acquires. Do not pass a constructed (as opposed to created) structure to PMIx_Regex2_free(3) <#man3-pmix-regex2-free>, as that would attempt to free storage the library did not allocate.

RETURN VALUE

PMIx_Regex2_construct returns no value (void).

NOTES

PMIx_Regex2_construct is an OpenPMIx convenience routine. The equivalent static initializer PMIX_REGEX2_STATIC_INIT may be used where a compile-time initialization is preferred.

EXAMPLES

Construct a structure:

pmix_regex2_t rex;
PMIx_Regex2_construct(&rex);


See also:

PMIx_Regex2_destruct(3) <#man3-pmix-regex2-destruct>, PMIx_Regex2_create(3) <#man3-pmix-regex2-create>, PMIx_Regex2_free(3) <#man3-pmix-regex2-free>, pmix_regex2_t(5) <#man5-pmix-regex2-t>


Copyright

2014-2026, OpenPMIx Community

November 5, 2026