TypeNode#instance_vars
should error when instance vars are not setup
#10662
Labels
good first issue
This is an issue suited for newcomers to become aquianted with working on the codebase.
help wanted
This issue is generally accepted and needs someone to pick it up
kind:bug
A bug in the code. Does not apply to documentation, specs, etc.
kind:feature
topic:compiler:semantic
topic:lang:macros
In the compiler's processing, instance vars are only initialized after all top-level code has been analyzed. Thus accessing the instance vars in top-level code has no result.
This is unexpected and should be considered a bug.
TypeNode#instance_vars
should rather error if called before it has a meaningful value.Original discussion: https://forum.crystal-lang.org/t/unions-and-macro-methods/3243/7
The text was updated successfully, but these errors were encountered: