- Subject: Re: What's faster ?
- From: "John E. Davis" <davis>
- Date: Mon, 6 Aug 2001 13:09:17 -0400
Richard van Zon <rvanzon@xxxxxxxxxxxx> wrote:
>but I go for the popping method...
>I only looked for a way that I can make the compiler
>clear that for example 2 integer parameters are
The other method is just as good as long as your MAKE_INTRINSIC table
entry specifies that the function takes 2 integers. For this reason,
it is preferable to allow slang to handle the popping and argument
checking for you.
>Or is it safe to just use the add_intrinsic functions with a parameter
>count ?
Use, e.g.,
#define V SLANG_VOID_TYPE
#define I SLANG_INT_TYPE
.
.
MAKE_INTRINSIC_2("func", func, V, I, I),
.
.
#undef V
#undef I
This is preferable to using the pop functions.
>btw: I tested some stuff with LUA (another interpreter), but the embedding
>method of S-Lang is much better, I must say. maybe nice to hear :-)
That is good to hear. I have heard that LUA is quite fast; however, I
think that if you take advantage of slang's array syntax then slang
can be as fast as compiled C for many purposes.
Thanks,
--John
[2001 date index]
[2001 thread index]
[Thread Prev] [Thread Next]
[Date Prev] [Date Next]