Beispiel #1
0
static void UT_LT2( DaoProcess *proc, DaoValue *p[], int N )
{
	DaoxUserType *A = (DaoxUserType*) p[0];
	DaoxUserType *B = (DaoxUserType*) p[1];
	DaoProcess_PutInteger( proc, A->value < B->value );
}
static void TRIA_Triangulate( DaoProcess *proc, DaoValue *p[], int N )
{
	DaoxTriangulator *self = (DaoxTriangulator*) DaoValue_TryCastCdata( p[0], daox_type_triangulator );
	DaoxTriangulator_Triangulate( self );
	DaoProcess_PutInteger( proc, self->triangles->size / 3 );
}
Beispiel #3
0
static void DaoIO_Isopen( DaoProcess *proc, DaoValue *p[], int N )
{
	DaoStream *self = & p[0]->xStream;
	DaoProcess_PutInteger( proc, (self->file != NULL) );
}
Beispiel #4
0
static void SYS_Time( DaoProcess *proc, DaoValue *p[], int N )
{
	DaoProcess_PutInteger( proc, time( NULL ) );
}
Beispiel #5
0
static void DaoBUF_Size( DaoProcess *proc, DaoValue *p[], int N )
{
	Dao_Buffer *self = (Dao_Buffer*) p[0];
	DaoProcess_PutInteger( proc, self->size );
}
Beispiel #6
0
static void SYS_Shell( DaoProcess *proc, DaoValue *p[], int N )
{
	DaoProcess_PutInteger( proc, system( DString_GetMBS( p[0]->xString.data ) ) );
}
Beispiel #7
0
static void UT_CastToInt( DaoProcess *proc, DaoValue *p[], int n )
{
	DaoxUserType *self = (DaoxUserType*) p[0];
	DaoProcess_PutInteger( proc, self->value );
}
Beispiel #8
0
static void CHANNEL_Buffer( DaoProcess *proc, DaoValue *par[], int N )
{
	DaoChannel *self = (DaoChannel*) par[0];
	DaoProcess_PutInteger( proc, self->buffer->size );
}
Beispiel #9
0
static void STD_SubType( DaoProcess *proc, DaoValue *p[], int N )
{
	DaoType *tp1 = DaoNamespace_GetType( proc->activeNamespace, p[0] );
	DaoType *tp2 = DaoNamespace_GetType( proc->activeNamespace, p[1] );
	DaoProcess_PutInteger( proc, DaoType_MatchTo( tp1, tp2, NULL ) );
}
Beispiel #10
0
static void FRAME_Size( DaoProcess *proc, DaoValue *p[], int N )
{
	DaoxDataFrame *self = (DaoxDataFrame*) p[0];
	DaoProcess_PutInteger( proc, DaoxDataFrame_SliceSize( self, self->original ) );
}