2011/10/4 cobines <[email protected]>: > 2011/10/4 silvioprog <[email protected]>: >> I'm needing to use in the uses clause, as I showed in my first >> example. But in the uses clause the FPC is not accepting the >> compilation. > > I think it is not possible as it seems the constants are not declared > while in the interface uses section. You can use it in the uses > implementation section. Checked with FPC trunk too. > > unit test2; > {$mode objfpc}{$H+} > interface > uses > LCLVersion > {$IF DECLARED(lcl_fullversion)} > {$ERROR interface} > {$ENDIF} > ; > > implementation > > {$IF DECLARED(lcl_fullversion)} > {$ERROR implementation} > {$ENDIF} > > begin > end. > > $ fpc test2.pas > Free Pascal Compiler version 2.7.1 [2011/09/09] for i386 > Copyright (c) 1993-2011 by Florian Klaempfl and others > Target OS: Win32 for i386 > Compiling test2.pas > test2.pas(17,4) Error: User defined: implementation > > -- > cobines
I solved my problem using a manual definition(*), without use the LCLVersion. Thanks to all. (*) http://code.google.com/p/lazsolutions/source/browse/trunk/Core/lazsolutions.inc -- Silvio Clécio =============================================== Blog - <silvioprog.com.br> Twitter - <twitter.com/silvioprog> Facebook - <facebook.com/silvioprog> LazSolutions - <code.google.com/p/lazsolutions> LazWebSolutions - <code.google.com/p/lazwebsolutions> Lazarus-BR - <groups.google.com.br/group/lazarus-br?hl=pt-BR> =============================================== * Conheça nosso canal IRC sobre Lazarus: #lazarus-br * =============================================== -- _______________________________________________ Lazarus mailing list [email protected] http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
