If you're using VSCode, go to this guide and follow the section 1.13: Troubleshooting. This will show you how to run a Haxe program with Debug support; if you run the application this way, the program will give VSCode the information necessary to highlight the exact line that contains the error.
I've had to post this or something like it numerous times. The docs should contain a dedicated page for it because people keep coming to me with "it gives a null error" and then don't tell me where the null error is because it doesn't tell you unless you follow that guide.