abc/src/opt/fxu/fxuList.c
/**Function*************************************************************

  Synopsis    [Adds the entry in the middle of the list after the spot.]

  Description [Assumes that spot points to the link, after which the given
  link should be added. Spot cannot be NULL or the tail of the list.
  Therefore, the head and the tail of the list are not changed.]
               
  SideEffects []

  SeeAlso     []

***********************************************************************/
Function
Synopsis    [Adds the entry in the middle of the list after the spot.]

Description [Assumes that spot points to the link, after which the given
link should be added. Spot cannot be NULL or the tail of the list.
Therefore, the head and the tail of the list are not changed.]




Function Synopsis [ Adds the entry in the middle of the list after the spot . ] Description [ Assumes that spot points to the link after which the given link should be added . Spot cannot be NULL or the tail of the list . Therefore the head and the tail of the list are not changed . ]
void Fxu_ListDoubleAddPairMiddle( Fxu_Double * pDiv, Fxu_Pair * pSpot, Fxu_Pair * pLink )
{
    Fxu_ListPair * pList = &pDiv->lPairs;
    assert( pSpot );
    assert( pSpot != pList->pTail );
    pLink->pDPrev = pSpot;
    pLink->pDNext = pSpot->pDNext;
    pLink->pDPrev->pDNext = pLink;
    pLink->pDNext->pDPrev = pLink;
    pList->nItems++;
}
void Fxu_ListDoubleAddPairMiddle ( Fxu_Double * pDiv , Fxu_Pair * pSpot , Fxu_Pair * pLink ) { Fxu_ListPair * pList = & pDiv -> lPairs ; assert ( pSpot ) ; assert ( pSpot != pList -> pTail ) ; pLink -> pDPrev = pSpot ; pLink -> pDNext = pSpot -> pDNext ; pLink -> pDPrev -> pDNext = pLink ; pLink -> pDNext -> pDPrev = pLink ; pList -> nItems ++ ; }
Function
Synopsis    [Adds the entry in the middle of the list after the spot.]
Function Synopsis [ Adds the entry in the middle of the list after the spot . ]