aboutsummaryrefslogtreecommitdiff
path: root/gdb/check-include-guards.py
AgeCommit message (Collapse)AuthorFilesLines
2025-04-08Update copyright dates to include 2025Tom Tromey1-1/+1
This updates the copyright headers to include 2025. I did this by running gdb/copyright.py and then manually modifying a few files as noted by the script. Approved-By: Eli Zaretskii <eliz@gnu.org>
2025-03-10Fix check-include-guards.pyTom Tromey1-6/+13
I noticed that check-include-guards.py doesn't error in certain situations -- but in situations where the --update flag would cause a file to be changed. This patch changes the script to issue an error for any discrepancy. It also fixes the headers that weren't correct. Approved-By: Simon Marchi <simon.marchi@efficios.com>
2024-12-18Add an include-checking scriptTom Tromey1-0/+127
This adds a new Python script that checks the header guards of all gdb source files. It enforces a fairly strict formatting and naming scheme. In particular, for a file "x/y-z.h" (relative to the repository root), the include guard will be named "X_Y_Z_H". Only the '#ifndef' form is allowed, not "#if !defined(...)". The trailing comment on the "#endif" is also required. The script also tries to update files that appear to have the required lines if they are in the wrong form or use the wrong name. Reviewed-By: Tom de Vries <tdevries@suse.de>