mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 15:22:04 +00:00
Preserve the current class across protocol defs.
It seems that protocol defs are allowed in class implementations, so don't let the protocol def kill the current class for the class implementation.
This commit is contained in:
parent
2be07fd652
commit
a7cfe3b215
1 changed files with 9 additions and 4 deletions
|
@ -1502,10 +1502,15 @@ classdef
|
|||
;
|
||||
|
||||
protocoldef
|
||||
: PROTOCOL protocol_name
|
||||
protocolrefs { protocol_add_protocols ($2, $3); $<class>$ = 0; }
|
||||
methodprotolist { protocol_add_methods ($2, $5); }
|
||||
END { current_class = 0; (void) ($<class>4); }
|
||||
: PROTOCOL { $<class_type>$ = current_class; }
|
||||
protocol_name
|
||||
protocolrefs { protocol_add_protocols ($3, $4); $<class>$ = 0; }
|
||||
methodprotolist { protocol_add_methods ($3, $6); }
|
||||
END
|
||||
{
|
||||
current_class = $<class_type>2;
|
||||
(void) ($<class>5);
|
||||
}
|
||||
;
|
||||
|
||||
protocolrefs
|
||||
|
|
Loading…
Reference in a new issue