Thursday, February 22, 2024

Rust pop-quiz answer: simplifying parsing lines code

#Rust pop-quiz answer to simply parsing lines of data.

THIS is more like it!



That is: after writing a generic parse_lines()-fn in string_utils



Allowing me to write a parse_data()-fn in file_utils, simply. 




For context, the three functions, COMBINED, with two new functionalities are less lines of code than the original line-parser-fn.

No comments:

Post a Comment