File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -21,10 +21,10 @@ class VisitorBase {
21
21
22
22
// we want to override the default swift visitor behaviour of chaining calls to immediate
23
23
// superclasses by default and instead provide our own TBD default (using the exact type).
24
- // Moreover if the implementation class has translate##CLASS##KIND (that uses generated C++
25
- // classes), we want to use that. We detect that by comparing the member function pointer to the one
26
- // for a private undefined member function of the same name and signature in {Ast,Type}VisitorBase,
27
- // which will be shadowed (and thus different) in case the implementation class has it .
24
+ // Moreover, if the implementation class has translate##CLASS##KIND (that uses generated C++
25
+ // classes), we want to use that. We detect that by checking its return type. If it is different
26
+ // from void (which is what is returned by a private unimplemented member function here) it means
27
+ // we have implemented it in the visitor .
28
28
#define DEFAULT (KIND, CLASS, PARENT ) \
29
29
public: \
30
30
void visit##CLASS##KIND(swift::CLASS##KIND* e) { \
You can’t perform that action at this time.
0 commit comments