Skip to content

docs: note Type API only guaranteed for Haxe-generated types - #13024

Open
TrueFurina wants to merge 1 commit into
HaxeFoundation:developmentfrom
TrueFurina:docs/type-api-haxe-generated-only
Open

TrueFurina wants to merge 1 commit into
HaxeFoundation:developmentfrom
TrueFurina:docs/type-api-haxe-generated-only

Conversation

@TrueFurina

Copy link
Copy Markdown

Summary

Per #6113 (from discussion in #5645): Type.resolveClass() cannot resolve external/native types (e.g. classes declared with extern on JS/Java/C#/Python), which is confusing for newcomers. Adds a notice in the Type API docs.

Changes

  • std/Type.hx: resolveClass doc now states:
    • the API is only guaranteed to work with types generated by the Haxe compiler
    • external (native) types declared with extern are not registered in the Haxe runtime and may not be resolvable by name

Verification

  • Syntax: comment-only change in a Haxe doc block; no code behaviour altered

Comment thread std/Type.hx
@@ -1,296 +1,301 @@
/*

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems the line ending may have changed, which has messed up the diff. Please change it back in your editor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants