PhPStorm shows Actionscript functions as "unused" when they're only called in other files
Since the most recent update, PhpStorm has stopped identifying when my functions are used if they're called in files separate to the one in which they're defined.
Before the update everything was working as it should, but after running the update, any time a function was called that wasn't defined in the same file where it was called, it showed up as not being a function (didn't have the "function" formatting, couldn't go to declaration), but flagging the main project directory as sources root seemed to fix that.
However, where the functions themselves are defined, PhpStorm still identifies them as "unused functions".
Please sign in to leave a comment.
What do these functions look like? Global functions from files included via `include "file_name"` are indeed marked as not resolved, but this is the age-old issue (https://youtrack.jetbrains.com/issue/IDEA-72546)? not smth introduced recently.
If your problem looks different, please provide a sample project that shows it up.
Note also that AS support in PHPStorm is very limited and is not maintained, you need IDEA Ultimate for working with Flex/Flash
Actually yes, this seems to be the same problem, however it is definitely not an issue I was having until very recently. I haven't really configured my IDE for Flash at all though, so it may have been a default setting which changed with a recent update?
I notice that this problem doesn't occur when using Javascript files. I don't actually require any Actionscript-specific help from PhpStorm, I just prefer the IDE in general since I use it for other development. Do you know if there's a way for me to tell PhpStorm to treat .as files like they were Javascript? I think this would probably solve my problem.
Hi there,
>Do you know if there's a way for me to tell PhpStorm to treat .as files like they were Javascript? I think this would probably solve my problem.
Easy -- just assign the *.as pattern (or whatever other extension is required) to JavaScript in "Settings/Preferences | Editor | File Types" -- it will be removed from Actionscript and re-assigned to JavaScript.
NOTE: it's IDE-wide setting and affects ALL projects.