robhagemans / pcbasic

PC-BASIC - A free, cross-platform emulator for the GW-BASIC family of interpreters
http://www.pc-basic.org
Other
397 stars 48 forks source link

Fix CIRCLE regression #149

Closed rbergen closed 2 years ago

rbergen commented 3 years ago

This fixes #136 by explicitly checking if the start and stop angle arguments are set to None when calculating the octants. Previously, if one was set to 0.0, the octant calculation for the angle in question would be skipped due to the numeric value evaluating to False.

robhagemans commented 3 years ago

Thanks, this looks completely correct. I'll merge into develop soon and it may make sense to do an intermediate release - I have only minimally looked at this project for a while, good to see interest in fixing bugs!

rbergen commented 3 years ago

Well, I think this is a great project worth contributing to, and I do like solving this type of puzzle. Looking at the issue list, there's a few others I may be able to help out with (like #133 and #132), and I will do so when I can find the time to do so. The MacOS-related ones I can't debug because I don't have a MacOS machine, and some others (#128, specifically) do look like they are way over my head. I'd be honoured if you do decide to merge some of my contributes and include them in an intermediate release. :)

nganfei commented 3 years ago

Previously, if one was set to 0.0, the octant calculation for the angle in question would be skipped due to the numeric value evaluating to False.

thanks. if I changes my program to circle(100, 100), 50, , 0.01, 1.57, the result is correct.

rbergen commented 3 years ago

@nganfei Thank you for confirming that.

robhagemans commented 2 years ago

Merged