diff options
author | Melody Horn <melody@boringcactus.com> | 2021-03-25 19:29:31 -0600 |
---|---|---|
committer | Melody Horn <melody@boringcactus.com> | 2021-03-25 19:29:31 -0600 |
commit | 957721e40a8bed5907319da6b2b9053c3c079527 (patch) | |
tree | 4965e768987bf20ffc0d568c6eb39e0ccf77a32a | |
parent | b83e916ec888b38b15a242c673c89da39b52a8e7 (diff) | |
download | yapymake-957721e40a8bed5907319da6b2b9053c3c079527.tar.gz yapymake-957721e40a8bed5907319da6b2b9053c3c079527.zip |
keep trailing newlines from polluting macros
-rw-r--r-- | yapymake/makefile/__init__.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/yapymake/makefile/__init__.py b/yapymake/makefile/__init__.py index a5cb19d..be04a5b 100644 --- a/yapymake/makefile/__init__.py +++ b/yapymake/makefile/__init__.py @@ -101,6 +101,9 @@ class Makefile: # make sure we don't process an ambiguous line as both an include and something else continue + # TODO figure out if this is always safe here + line = line.rstrip('\n') + # decide if this is a macro or rule line_type = 'unknown' line_tokens = tokenize(line) |