FlexBuilder 编译器错误 - IWatcherSetupUtil2 等
我在使用 FlashBuilder 时遇到了一个问题,这显然是一个编译器错误,但我无法找到它。
当我的项目在 FlashBuilder 中编译时,我收到以下编译器错误:
Type was not found or was not a compile-time constant: [mx.binding]::IBindingClient
Type was not found or was not a compile-time constant: [mx.binding]::IWatcherSetup2
Type was not found or was not a compile-time constant: [mx.core]::IStateClient2
报告这些错误时没有路径或位置。
我的项目是一个flex4项目,复杂程度适中。它有 6 个 swc 项目,在 swf 项目中引用它们。 (swf 项目是报告错误的项目)。
ANT 构建脚本可以很好地编译项目。
该问题存在于不止 1 台 PC 上。
我如何开始追踪导致问题的原因?
I'm having a problem with FlashBuilder in what is clearly a compiler bug, but I can't track it down.
When my project is compiled inside FlashBuilder, I'm getting the following compiler errors:
Type was not found or was not a compile-time constant: [mx.binding]::IBindingClient
Type was not found or was not a compile-time constant: [mx.binding]::IWatcherSetup2
Type was not found or was not a compile-time constant: [mx.core]::IStateClient2
These errors are reported without a path or location.
My project is a flex4 project, moderately complex. It has 6 swc projects, which are referenced within a swf project. (The swf project is the one that's reporting the error).
The ANT build script compiles the project fine.
The problem exists on more than 1 PC.
How do I start tracking down what's causing the problem?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
当 SWC 和主项目之间存在版本不匹配时,我见过类似的错误。确保您的所有库都是针对与您的项目相同的 SDK 进行编译的。如果您正在使用框架或其他开源库,我强烈建议您获取源代码并重新编译。
还要检查以确保所有项目都针对相同的播放器版本。
我的印象是,这种类型的错误更可能发生在单点版本中,而不是主要版本中,但似乎非常不一致。
更多信息
I've seen similar errors when there is a version mismatch between a SWC and the main project. Make sure all your libraries are compiled against the same SDK that your project is. IF you're using frameworks or other open source libraries, I strongly recommend you get the source and re-compile.
Also check to make sure that all the projects target the same player version.
My impression is that this type of error is more likely to occur in point releases than major releases, but it seems to be very inconsistent.
More Info
我今天在我的项目中看到了这个问题。事实证明,我的一个项目使用的是 3.5 sdk,而其他项目使用的是 4.0。我将3.5项目的sdk更改为4.0,错误消失了。谢谢!
I saw that problem with my project today. Turns out that one of the projects that I had was using the 3.5 sdk while the others were using 4.0. I changed the sdk for the 3.5 project to 4.0 and the error disappeared. Thanks!