HaxeFoundation / HaxeFoundation/haxe

Using `haxe.macro.Compiler.IncludePosition` produce a error

Open
#6,252 3 comments 0 reactions 1 assignee Claimed by @andyli View on GitHub
Dominant language
Haxe
Stars
6.9k
Forks
715
Avg merge
2d 2h
Merged PRs (30d)
11

Description

Haxe code:
```haxe
private static function __init__() : Void
{
haxe.macro.Compiler.includeFile("file.js", haxe.macro.Compiler.IncludePosition.Inline);
}
```
Resilt:
```shell
Test.hx:17: characters 55-97 : haxe.macro.Expr should be haxe.macro.IncludePosition
Test.hx:17: characters 55-97 : { pos : haxe.macro.Position, expr : haxe.macro.ExprDef } should be haxe.macro.IncludePosition
Test.hx:17: characters 55-97 : For optional function argument 'position'
```

I think, this behavior is strange. May be we must remove IncludePosition abstract at all?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.