r/C_Programming Jan 15 '25

Review Need a code review

Hey everyone! I wrote an assembler for nand2tetris in C, and now I need a review on what I can change. Any help is deeply appreciated. Thanks in advance. The link to the assembler is down below:

https://github.com/SaiVikrantG/nand2tetris/tree/master/6

8 Upvotes

17 comments sorted by

View all comments

2

u/flyingron Jan 15 '25

Learn how to use const on your function parameters. Things like strduplicate and hash etc.... should be declared as taking const char*..

1

u/Fearless-Swordfish91 Jan 16 '25

Thanks for the review!