SDL-News: Using code C in SDL


Subject: SDL-News: Using code C in SDL
From: Manne Andrea (tequila77xyz#libero.it)
Date: Fri Apr 05 2002 - 11:44:37 GMT


I'm a italian student
I have this problem with SDL
I want to import a Duration sort from SDL to C program

In SDL i write this

DCL

 x, y Duration;

procedure tempo;

fpar x Duration, y Duration;

returns Duration;

external;

In C program i write this

int <----- NO CORRECT tempo (int <----- NO CORRECT x, int <-- NO CORRECT y)
{
 
 int <----- NO CORRECT z;
 z = x + y;
 return z;
}

the SDL generate this error

error C2115: '=' : incompatible types

Instead type INT what i must write?

Can you help me ?

THX

I'm a italian student
I have this problem with SDL
I want to import a Duration sort from SDL to C program
 
In SDL i write this
 
 
 

DCL

 x, y Duration;

 

procedure tempo;

fpar x Duration, y Duration;

returns Duration;

external;

 

In C program i write this

 

int <----- NO CORRECT      tempo (int          <----- NO CORRECT   x, int <-- NO CORRECT y)
{
 
 int <----- NO CORRECT            z;
 z = x + y;
 return z;
}

 

the SDL generate this error

error C2115: '=' : incompatible types

Instead type INT what i must write?

 

Can you help me ?

 

THX

--End text from "Manne Andrea" to sdlnews --- For extra SDL Forum Society benefits join at



This archive was generated by hypermail 2a23 : Thu May 09 2013 - 16:05:49 GMT