[Gambas-user] Another crash.

Benoît Minisini gambas at ...1...
Sun Jan 9 01:30:17 CET 2011


> > Another point. The following code is useless:
> > 
> > #If SYSTEM = "Linux"
> > Private sSystem As String = "Linux"
> > #Else If SYSTEM = "FreeBSD"
> > Private sSystem As String = "FreeBSD"
> > #Else If SYSTEM = "OpenBSD"
> > Private sSystem As String = "OpenBSD"
> > #Else If SYSTEM = "NetBSD"
> > Private sSystem As String = "NetBSD"
> > #Else If SYSTEM = "Solaris"
> > Private sSystem As String = "Solaris"
> > #Else
> > Private sSystem As String = "Unknown"
> > #Endif
> > 
> > #If ARCHITECTURE = "x86"
> > Private sArchitecture As String = "x86"
> > #Else If ARCHITECTURE = "x86_64"
> > Private sArchitecture As String = "x86_64"
> > #Else If ARCHITECTURE = "ARM"
> > Private sArchitecture As String = "ARM"
> > #Else If ARCHITECTURE = "PPC"
> > Private sArchitecture As String = "PPC"
> > #Else
> > Private sArchitecture As String = "Unknown"
> > #Endif
> > 
> > Just use System.Family and System.Architecture !
> 
> sArchitecture, etc are in fact checked against System.Architecture!
> So, functionally pointless, but idea is check if preprocessors works.
> 
> Jussi

Aaa... I didn't understood. Good idea! :-)

-- 
Benoît Minisini




More information about the User mailing list