Page 1 of 1

Compile from workspace window compiles current document

Posted: Thu May 19, 2011 4:43 pm
by engicoder
I have a workspace with multiple files. For example:

- MyProject files
  • - Header Files
    - Resource Files
    - Source Files
    • main.c
      helper.c
If I open helper.c as the current document and then right click on main.c in the workspace window and select Compile, it will compile helper.c instead of main.c. This is true even if the current document is a output window such as "Compiler".
It seems to behave the same as selecting Compile from the Compile menu.

Ben

Posted: Thu May 19, 2011 11:45 pm
by jussij
Hi Ben,

I can confirm that you have found a bug :(
It seems to behave the same as selecting Compile from the Compile menu.

I suspect you are correct.

Cheers Jussi

Posted: Fri May 20, 2011 12:25 am
by jussij
I have identified the cause of this issue and it should be fixed in the next beta release :)

This issue is the compiler command line is calculated using the $fn macro tag and by definition this tag will return the currently active directory and hence the reason for the wrong file being compiled.

The fix will be to make sure the selected file also becomes the active file ;)

Cheers Jussi

Posted: Wed May 25, 2011 12:58 am
by jussij
This issue should now be fixed in the latest beta version found here:

http://www.zeusedit.com/z300/ze397f-beta.zip

Cheers Jussi