Sometimes after a build I get a lot of errors of this kind or similar:
1067: Implicit coercion of a value of type mx.events:CollectionEvent to an unrelated type flash.events:Event.
After I clean the project it works again.
Some days ago it started to happen very often so that I got to clean the projects all the time and it's a bit time consuming.
Is there a fix for this behaviour?
So are you actually dispatching a collection event and typing it as a generic event? Not that it couldn't work but it sounds like a warning worth paying attention to. Willing to share the code where this is happening?
I'm dispatching the CollectionEvents and in my listeners I handle them. So I never cast them to a Event. That's why I'm a bit confused =)
In general it's not only about CollectionEvents. It seems that the warning is shown for every event.
I would like so share some code to show this, but it only happens sometimes if my big library project is changed. So it seems that it's a problem with the library handling.
I tried recreating this problem in a simple project but unfortunately the error didn't occur.