/* Copyright (C) 1993 by Thomas Glen Smith. All Rights Reserved. */
/* enlist APL2 V1.0.0 ***************************************************
* Creates a simple vector whose items are the simple scalars in rite. *
***********************************************************************/
#define INCLUDES APLCB
#include "includes.h"
Aplcb enlist(rite)
Aplcb rite;
{
Enlista; Enlistb; Errinit; Errstop; Getcb;
extern int aplerr;
int count, datatype;
Aplcb out;
if (errinit())
return(errstop(0,NULL,rite,NULL));
count = datatype = 0;
enlista(&count, &datatype, rite);
if (count == 0 && datatype == APLAPL)
datatype = APLCHAR;
out = getcb(NULL,count,datatype+APLTEMP,1,NULL);
if (aplerr == 0 && count)
enlistb(datatype, out->aplsize, out->aplptr.aplchar, rite);
return(errstop(0,NULL,rite,out));
}