Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit b84bc7a

Browse files
committed
Avoid "warning: no newline at end of file" in importlib.h.
1 parent 32bc80c commit b84bc7a

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

Python/freeze_importlib.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ def main(input_path, output_path):
2525
with open(output_path, 'w', encoding='utf-8') as output_file:
2626
output_file.write('\n'.join(lines))
2727
output_file.write('/* Mercurial binary marker: \x00 */')
28+
# Avoid a compiler warning for lack of EOL
29+
output_file.write('\n')
2830

2931

3032
if __name__ == '__main__':

Python/importlib.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3029,4 +3029,4 @@ unsigned char _Py_M__importlib[] = {
30293029
12,17,6,2,12,47,18,25,12,23,12,15,24,30,6,1,
30303030
6,3,12,54,
30313031
};
3032-
/* Mercurial binary marker: */
3032+
/* Mercurial binary marker: */

0 commit comments

Comments
 (0)