HaxeFoundation / HaxeFoundation/hxcpp
@:generic ignores @:unreflective
- Dominant language
- C++
- Stars
- 330
- Forks
- 227
- Avg merge
- 2d 16h
- Merged PRs (30d)
- 18
Description
When a Haxe class is annotated with both @:generic and @:unreflective, the corresponding C++ class still retains the reflection machinery.
For example, compiling the following code with these annotations generates a class named MyClass_Int.cpp, which contains declarations such as `HX_DEFINE_DYNAMIC_FUNC0(MyClass_Int_obj, get, return)`.
I am using Haxe 4.3.4 (but Haxe 4.3.3 exhibits the same behaviour).
```haxe
@:generic
@:unreflective
class MyClass {
var _v: T;
public function new(v: T) _v = v;
public function get() return _v;
}
class Main {
static function main() {
trace(new MyClass(1).get());
}
}
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.