This function makes a new copy of a general context, using the memory
allocation functions in the context, if set, to get the necessary memory.
Otherwise malloc() is used. The result is NULL if the memory cannot be
There is a complete description of the PCRE2 native API in the
page and a description of the POSIX API in the