HaxeFoundation / intellij-haxe

Haxe plugin for IntelliJ Platform based IDEs (IDEA, Android-Studio)
http://intellij-haxe.org
Apache License 2.0
222 stars 99 forks source link

Compiling for AIR, reference to FileStream is flagged by Intellij as "unresolved symbol" #850

Open Vectorpark opened 6 years ago

Vectorpark commented 6 years ago

I'm compiling with OpenFL to the Adobe AIR target on MacOS 10.13.3. In the following sample class, references to FileStream are flagged by Intellij as "unresolved symbol", and the methods and properties of the FileStream class are not exposed:

package;

import openfl.display.Sprite;
import flash.filesystem.FileStream;

class Main extends Sprite {

    public function new () {

        super ();

        var fileStream:FileStream = new FileStream();
    }
}

The project compiles and runs successfully.

EricBishton commented 6 years ago

I'll have to test this. It's either a bug in the plugin, or it's a library configuration issue.

The plugin doesn't get all of the information that the compiler does from haxelib, particularly where OpenFL is concerned, because OpenFL/Lime go to some effort to hide sources during compiler '--display' calls. I don't expect that to be a problem with AIR APIs that are external, so I'm going to investigate.

@Vectorpark, can you please provide OS, IDEA, and plugin version details? Thanks.

Vectorpark commented 6 years ago

Sure thing: MacOS 10.13.3 IDEA 2018.1.2, Build #IU-181.4668.68 Haxe Toolkit Support version 1.0.2

CanIGetaPR commented 3 years ago

Did a little investigating, most openfl classes are available in openfl-haxelib-root/lib/

Where as this FileStream class is only in openfl-haxelib-root/packages/

Thus, perhaps this error of it thinking the class' package is wrong is relevant:

image