OpenersNotesSection(Spacer1)Details

Calling MLDestroyMark() releases memory associated with the storage of expressions recorded after the mark.

MLDestroyMark() is declared in the MathLink header file (RefLink[mathlink.h, paclet:ref/file/mathlink.h]).

OpenersPrimaryExamplesSection(Spacer1)Examples  (1)

OpenersExampleSection0(Spacer1)Basic Examples  (1)

#include "mathlink.h"

/* create a mark in a link, read some data, then back up */

void f(MLINK lp)
{
	MLMARK mark;

	mark = MLCreateMark(lp);
	if(mark == (MLMARK)0)
		{ /* mark creation failed */ }

	/* read data from the link */

	MLSeekToMark(lp, mark, 0);

	MLDestroyMark(lp, mark);
}

({{DocumentationFooterIconsRelatedFunction.png, ({{See Also}, {(NonWLLink[MLCreateMark(), paclet:ref/c/MLCreateMark])  ▪  (NonWLLink[MLSeekToMark(), paclet:ref/c/MLSeekToMark])}})}})

({{DocumentationFooterIconsRelatedTutorial.png, ({{Tutorials}, {▪(RefLinkPlain[Manipulating Expressions in External Programs, paclet:tutorial/ManipulatingExpressionsInExternalPrograms])}})}})