summaryrefslogtreecommitdiff
BranchCommit messageAuthorAge
masterUse double-equals to compare value instead of identityzlg2 years
 
TagDownloadAuthorAge
dupekill-1.2dupekill-1.2.tar.gz  dupekill-1.2.tar.bz2  dupekill-1.2.tar.xz  dupekill-1.2.zip  zlg6 years
>Solve Exercise 6-6: A simple `#define` processorzlg2-2/+200 This exercise is probably the most challenging "function puzzle" thus far. Modifying getword(), using various states, and the hashtable all create an example of how small building blocks can work together to make something. The implementation is very simple and nowhere near completely supporting '#define', but that's not the point. To properly support it, you'd need to build an entire preprocessor/parser, and that's far beyond the scope of both the exercise and book.