Another problem with uses

edited 3:53AM in FastScript
Hi,

i tested the following script with 3 files :

//Main.pas
Uses 'Global.pas', 'Unit1.pas' ;

Begin
GlobalTest ;
Unit1Test
End .


//Global.pas
Procedure GlobalTest ;
ShowMessage ('GLOBALTEST')
End ;
Begin
End.

//Unit1.pas
Uses 'Global.pas' ;
Procedure Unit1Test ;
Begin
GlobalTest ;
ShowMessage ('UNIT1TEST')
End ;
Begin
End.

Compilation results in "Identifier GlobalTest redefined.

What can i do ??

Thanks in advance

Willi



Comments

  • edited March 2004
    Uses directory is not working like Delphi uses. In your case 'global.pas' is included twice.
  • edited 3:53AM
    Yes, i realized it. But how can i solve my problem ?

    1. Use one big pas-file and

    2. hope that you fix the problem in a later version ?

    or is there another solution ?

    Thanks

    Willi
  • edited 3:53AM
    just remove 'uses' in unit1.
    I'll try to do something with this in the next release.

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.