/* DEC *SwapDecimal(ptr1, ptr2) * * ARGUMENT * ptr1 is a ptr to the source1 DEC structure. * ptr2 is a ptr to the source2 DEC structure. * * DESCRIPTION * Swaps the values of ptr1 and ptr2. * * SIDE EFFECTS * None. * * RETURNS * Returns pointer to ptr1 if successful, otherwise * returns GM_NULL. * * * POSSIBLE ERROR CODES * * GM_NULLPOINTER * * AUTHOR * Jared Levy * Copyright (C) 1988-1990 Greenleaf Software Inc. All rights reserved. * * MODIFICATIONS * */ #include #include "gmsystem.h" DEC *SwapDecimal(ptr1,ptr2) DEC *ptr1; DEC *ptr2; { DEC temp[1]; /* source must be supplied !! */ _MacStart(GM_DCPY); _MacInVar(ptr2,GM_NULL); _MacInVar(ptr1,GM_NULL); _MacDCopy(temp, ptr1); _MacDCopy(ptr1, ptr2); _MacDCopy(ptr2, temp); _MacRet(ptr1); }