[Gambas-devel] conditional compilation

chintan rao chintanraoh at ...176...
Fri Oct 6 15:30:26 CEST 2006


>> Hi,
>>
>> >From: Benoit Minisini <gambas at ...1...>
>> >To: mailing list for gambas developers <
>> > gambas-devel at lists.sourceforge.net
>> >
>> >
>> >I never really think about this feature. I think the a preprocessor
>>
>> should
>>
>> >be included inside the compiler, just after or during the tokenization
of
>>
>> the
>>
>> >source code.
>> >Note that at the moment, I found no need for a preprocessor in Gambas.
>>
>> Maybe
>>
>> >this should be asked first on the mailing-list.
>>
>> I have not coded much in gambas. This could be one possibility.
>> You could possibly have .
>>
>> #IF <classname>
>> code for classname
>> #ELSE
>> "error"
>> #ENDIF
>>
>> or we could have
>> #IFNDEF <classname>
>> "error"
>> #ENDIF
>>
>> This way you could even avoid #define statements.
>> Does this make it bit like c++/c ?I don't think so.
>> I think it is simple enough to understand for a Gambas user.
>> What do you think about this?
>>
>> yours sincerely
>> Chintan Rao H
>
>What does '#IF <classname>' means exactly?
>
>--
>Benoit Minisini


#IF <classname>
It means that if there exists by that name (classname) the code will be
compiled for that class.
I dont know weather this feature will be usefull.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/devel/attachments/20061006/7328bdaa/attachment.html>


More information about the Devel mailing list