I'm trying to compile a project with FF3.6 and I observe that it's not possible.
In an include module I have :
Type ty_SFC_09H
na1 As Byte
n As Word
End Type 'sizeOf = 3
Type ty_SFC_0DH
na1 As Byte
n As Word
End Type 'sizeOf = 3
Type ty_SFC_ERR
ec As Byte 'error code
End Type
Union uni_ANS_DETAILS
h09 As ty_SFC_09H 'offset = 20
h0D As ty_SFC_0DH 'offset = 20
er As ty_SFC_ERR
End Union
and in the CODGEN....DECLARES.INC the unions are located at the top of the file.
It results an Undefined Type for h09 As ty_SFC_09H 'offset = 20 at compile time !
Strange. Is it a different management of declaration order in FF3.6 / FF3.5 ?
Franck
Compiler PBWin 10.03
Yes, there were changes in 3.6 dealing with the order in which structures are outputted to the DECLARES file. Per the change log:
0000805: [New Feature Request] Tweak codegen output to place Equates/Types/Globals/Macros/Objects in better order (Paul Squires) - closed.
In your case, this change appears to cause problems.
To fix the problem you would need to move your code into a standalone include file rather than put it into your project via a module. You would then use an #INCLUDE <filename> in your FF_WINMAIN section.