diff options
author | Colin Snover | 2017-11-06 22:45:32 -0600 |
---|---|---|
committer | Colin Snover | 2017-12-03 20:27:42 -0600 |
commit | a5bc89102e790d38d23a0a220ee2d42baee647a1 (patch) | |
tree | 32c3bdb45c8cd7cf3ef9ea1f7af2c9337a079334 /backends/platform/psp | |
parent | ef33d8a2fb987f3fdbeb094aca2ecdfcd5b269ba (diff) | |
download | scummvm-rg350-a5bc89102e790d38d23a0a220ee2d42baee647a1.tar.gz scummvm-rg350-a5bc89102e790d38d23a0a220ee2d42baee647a1.tar.bz2 scummvm-rg350-a5bc89102e790d38d23a0a220ee2d42baee647a1.zip |
ALL: Remove obsolete register keyword
The register keyword was deprecated from the C++11 standard,
<http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2014/n4193.html#809>,
and removed from the C++17 standard,
<http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2015/n4340>, so
cannot exist in a well-formed C++17 program.
It has never done anything in GCC
<https://gcc.gnu.org/ml/gcc/2010-05/msg00113.html>
and because of the way it is specified in the standard, it is “as
meaningful as whitespace”
<http://www.drdobbs.com/keywords-that-arent-or-comments-by-anoth/184403859>.
The one remaining use of the register keyword is in the DS backend,
where it is used to create a local register variable using the
non-standard GCC Extended Asm feature.
Closes gh-1079.
Diffstat (limited to 'backends/platform/psp')
-rw-r--r-- | backends/platform/psp/memory.h | 2 | ||||
-rw-r--r-- | backends/platform/psp/trace.cpp | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/backends/platform/psp/memory.h b/backends/platform/psp/memory.h index d7c5420d64..f794eb0baf 100644 --- a/backends/platform/psp/memory.h +++ b/backends/platform/psp/memory.h @@ -33,7 +33,7 @@ // These instructions don't generate automatically but are faster then copying byte by byte inline void lwl_copy(byte *dst, const byte *src) { - register uint32 data; + uint32 data; asm volatile ("lwr %0,0(%1)\n\t" "lwl %0,3(%1)\n\t" : "=&r" (data) : "r" (src), "m" (*src)); diff --git a/backends/platform/psp/trace.cpp b/backends/platform/psp/trace.cpp index 50459dcea5..37f58c378a 100644 --- a/backends/platform/psp/trace.cpp +++ b/backends/platform/psp/trace.cpp @@ -86,8 +86,8 @@ void PspDebugTrace(bool alsoToScreen, const char *format, ...) { // void mipsBacktrace(uint32 levels, void **addresses) { // get the current return address - register byte *retAddr; - register byte *stackPointer; + byte *retAddr; + byte *stackPointer; GET_RET(retAddr); GET_SP(stackPointer); char string[100]; |