discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: data type polymorphism


From: Riccardo Mottola
Subject: Re: data type polymorphism
Date: Tue, 24 Mar 2015 20:05:53 +0100
User-agent: Mozilla/5.0 (X11; Linux i686; rv:35.0) Gecko/20100101 Firefox/35.0 SeaMonkey/2.32.1

Hi Maxthon,

Maxthon Chan wrote:
If you need to keep your code strictly C you can emulate this by (ab)using 
#include and #define and #ifdef like this:

from what I can understand, your solution switches types at compile time.

I need instead to do that at runtime. I get an NSImageRepresentation, analyze the bit depth and execute the same algorithm, but once on 8bit (char) and once with 16bit (short).

Riccardo



reply via email to

[Prev in Thread] Current Thread [Next in Thread]