aboutsummaryrefslogtreecommitdiff
path: root/gcc/fixed-value.c
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@acm.org>2020-09-11 08:23:32 -0700
committerNathan Sidwell <nathan@acm.org>2020-09-11 08:27:40 -0700
commit1be7bf7dab86d2fb33561b7eac1d2f527aa98b2c (patch)
treedd4900b73b3e973c7c08212277fe0077a635f1e6 /gcc/fixed-value.c
parent13144466f11036585389a0dc5826bf23d53d5616 (diff)
downloadgcc-1be7bf7dab86d2fb33561b7eac1d2f527aa98b2c.zip
gcc-1be7bf7dab86d2fb33561b7eac1d2f527aa98b2c.tar.gz
gcc-1be7bf7dab86d2fb33561b7eac1d2f527aa98b2c.tar.bz2
objc++: Always pop scope with method definitions [PR97015]
Syntax errors in method definition lists could leave us in a function scope. My recent change for block scope externs didn't like that. This reimplements the parsing loop to finish the method definition we started. AFAICT the original code was attempting to provide some error recovery. Also while there, simply do the token peeking at the top of the loop, rather than at the two(!) ends. gcc/cp/ * parser.c (cp_parser_objc_method_definition_list): Reimplement loop, make sure we pop scope. gcc/testsuite/ * obj-c++.dg/syntax-error-9.mm: Adjust expected errors.
Diffstat (limited to 'gcc/fixed-value.c')
0 files changed, 0 insertions, 0 deletions