正向类型未解决-Lazarus freepascal
我正在尝试使用以前从C成功使用的Pascal的外部库。为了使用此库,我已经提供了一个.h文件,一个.dll文件和.lib文件。
我使用H2PAS实用程序转换了.H文件,但是我遇到了以下错误(我怀疑与链接器有关):
Error: (5009) Forward type not resolved "XPRSbranchobject"
这似乎是有问题的行:
type
...
XPRSbranchobject = ^xo_user_branch_entity_s ;
我如何让Lazarus知道xo_user_branch_entity_s
是外部库的一部分吗?
I am trying to use an external library from Pascal that I have successfully used from C before. In order to use this library I have been provided a .h file, a .dll file and a .lib file.
I converted the .h file using the h2pas utility but I am getting the following errors (which I suspect are linker-related):
Error: (5009) Forward type not resolved "XPRSbranchobject"
This appears to be the offending line:
type
...
XPRSbranchobject = ^xo_user_branch_entity_s ;
How do I let Lazarus know that xo_user_branch_entity_s
is part of the external library?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以简单地写:
您必须确定您永远不会(DE)分配此对象(直接或通过指针);如果消息来源试图访问内部成员,则编译器将抱怨。
这意味着分配/交易是由DLL完成的。
它应该(可以吗?)工作...
You could simply write:
You must be sure you never (de)allocate such object (the record, either directly or via pointer); if the sources tries to access internal members, the compiler will complain.
This implies that allocation/deallocation is done by the DLL.
It should (could?) work...