diff options
author | Tom Tromey <tromey@adacore.com> | 2019-03-04 12:05:47 -0700 |
---|---|---|
committer | Tom Tromey <tromey@adacore.com> | 2019-03-12 10:45:37 -0600 |
commit | 17547186c25aa96d078a6ff9d61a55880fa009f4 (patch) | |
tree | b315e11c8585c492fa0dd1308c22ff5555c331e0 /gdb/common/ptid.h | |
parent | d3a70e03cf51c8fb6bc183eaff7559edffec2045 (diff) | |
download | gdb-17547186c25aa96d078a6ff9d61a55880fa009f4.zip gdb-17547186c25aa96d078a6ff9d61a55880fa009f4.tar.gz gdb-17547186c25aa96d078a6ff9d61a55880fa009f4.tar.bz2 |
Make null_ptid and minus_one_ptid "const"
This makes null_ptid and minus_one_ptid "const". I think this is an
improvement because it means they can't be accidentally modified.
2019-03-12 Tom Tromey <tromey@adacore.com>
* common/ptid.c (null_ptid, minus_one_ptid): Now const.
* common/ptid.h (null_ptid, minus_one_ptid): Now const.
Diffstat (limited to 'gdb/common/ptid.h')
-rw-r--r-- | gdb/common/ptid.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/common/ptid.h b/gdb/common/ptid.h index 31440c8..f5625a6 100644 --- a/gdb/common/ptid.h +++ b/gdb/common/ptid.h @@ -145,11 +145,11 @@ private: /* The null or zero ptid, often used to indicate no process. */ -extern ptid_t null_ptid; +extern const ptid_t null_ptid; /* The (-1,0,0) ptid, often used to indicate either an error condition or a "don't care" condition, i.e, "run all threads." */ -extern ptid_t minus_one_ptid; +extern const ptid_t minus_one_ptid; #endif /* COMMON_PTID_H */ |