[Mono-osx] #define and Operating System Specific Code
stifu at free.fr
Fri Oct 14 09:52:02 EDT 2011
You can detect the OS at runtime.
Andrew Ayre wrote:
> Following on from my previous question are there any suggestions on how
> to write cross-platform code that uses threads? Currently I have:
> Thread SerialThread = new Thread(new ThreadStart(SerialHandler));
> private void SerialHandler()
> NSAutoreleasePool Pool = new NSAutoreleasePool();
> Pool = null;
> For Windows and Linux I want to omit the autorelease pool code. I'm sure
> there must be a clever way that doesn't involve #if/#endif.
> thanks, Andy
> On 10/12/2011 3:52 PM, Andrew Ayre wrote:
>> Hi, where can I find a list of compiler defines that Mono provides to
>> identify the current operating system?
>> Thanks, Andy
> PGP Key ID: 0xDC1B5864
> Mono-osx mailing list
> Mono-osx at .ximian
View this message in context: http://mono.1490590.n4.nabble.com/define-and-Operating-System-Specific-Code-tp3898256p3904918.html
Sent from the Mono - OSX mailing list archive at Nabble.com.
More information about the Mono-osx