Closed WeebNetsu closed 1 year ago
You can use a global type
forward declaration as described here:
https://github.com/teal-language/tl/issues/355#issuecomment-1208065660
Try adding global type ComType
at the top of player.d.tl
and global type PlayerType
at the top of com.d.tl
!
Yes! This works! Thank you!
I have 2 files, player.d.tl
and com.d.tl
As you can see, both the ComType and PlayerType require each other in some way... However, this causes a
no type information for required module error check
error to pop up, since com.d.tl cannot import player.d.tl if player.d.tl is already importing com.d.tl.It would be nice if circular imports/circular dependency was allowed, especially in projects using Love2D, this feature will be very much appreciated