r/C_Programming • u/TheAmazingFreddyAdam • Sep 05 '26
How to get Code Review?
Hello yall,
just wondering if there was a community where I can share my code to get advice and such, so like a Code Review.
This might also be another excuse to look at other peoples code and such, but I mainly want to get advice for my code.
Im not really familiar with the coding community, I just code and make projects by myself as a hobby.
cheers, and have a good day.
5
Upvotes
View all comments
Show parent comment
1
u/TheAmazingFreddyAdam Sep 07 '26
Loved your feedback lol. I should note that the unknown_error is a placeholder at the moment, just because not many processes produce an unknown error that I thought it would be fine to keep as it will be easy to track down, but ill start as you said, "make it known". I think I should also explain the halt for the cpu_t is used generally as a flag that the cpu has stopped and doesnt really explain the state of the CPU (if it has halted due to an error or the program was exited from) which is why I made the tern_quit function that has a kinda-empty switch statement, but you are right, I shouldn't write/keep unfinished code. I also like the idea of no-op for 0, there was this other emulator which im following its development which had the same thing so I was planning on doing the same.
For my math source file, some of the indentations/formatting might be wrong because everything was originally in the same source file and moving them might have messed them up.
but in retrospect, I should totally need to improve on these things. especially my naming scheme/what I name my variables & functions which is why I worry about my future children names.
but in all seriousness, thank you for taking time out of your schedule to review my code. Have a nice day.
I should also say, BROO I cant lock in, why is ternary division to hard to implement ðŸ˜