From 8f8be9c2b10618b733e212846b54d6378a466a78 Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Sat, 9 Jan 2021 12:51:41 +0530 Subject: [PATCH] Add notice to not edit generated code --- gen-key-constants.py | 2 +- glfw/glfw3.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/gen-key-constants.py b/gen-key-constants.py index 8ad5dbff0..4701f25e5 100644 --- a/gen-key-constants.py +++ b/gen-key-constants.py @@ -116,7 +116,7 @@ last_code = start_code + len(functional_key_names) - 1 def patch_file(path: str, what: str, text: str, start_marker: str = '/* ', end_marker: str = ' */') -> None: - start_q = f'{start_marker}start {what}{end_marker}' + start_q = f'{start_marker}start {what} (auto generated by gen-key-constants.py do not edit){end_marker}' end_q = f'{start_marker}end {what}{end_marker}' with open(path, 'r+') as f: diff --git a/glfw/glfw3.h b/glfw/glfw3.h index 14f05eb7b..a1541d020 100644 --- a/glfw/glfw3.h +++ b/glfw/glfw3.h @@ -342,7 +342,7 @@ extern "C" { * @{ */ -/* start functional key names */ +/* start functional key names (auto generated by gen-key-constants.py do not edit) */ typedef enum { GLFW_FKEY_FIRST = 0xe000, GLFW_FKEY_ESCAPE = 0xe000,