comparison gen/functions.cpp @ 1250:4b0b470bb2f9

Automated merge with http://hg.dsource.org/projects/ldc
author Christian Kamm <kamm incasoftware de>
date Tue, 21 Apr 2009 18:57:29 +0200
parents 01909bd1132c 871ae029ff49
children 0c8048e13867
comparison
equal deleted inserted replaced
1248:01909bd1132c 1250:4b0b470bb2f9
384 fdecl->ir.resolved = true; 384 fdecl->ir.resolved = true;
385 385
386 Logger::println("DtoResolveFunction(%s): %s", fdecl->toPrettyChars(), fdecl->loc.toChars()); 386 Logger::println("DtoResolveFunction(%s): %s", fdecl->toPrettyChars(), fdecl->loc.toChars());
387 LOG_SCOPE; 387 LOG_SCOPE;
388 388
389 // queue declaration unless the function is abstract without body 389 // queue declaration unless the function is abstract without body;
390 if (!fdecl->isAbstract() || fdecl->fbody) 390 // bodyless functions in an abstract class are considered abstract
391 ClassDeclaration* cd = fdecl->parent->isClassDeclaration();
392 bool isabstract = fdecl->isAbstract() || (cd && cd->isAbstract());
393 if (!isabstract || fdecl->fbody)
391 { 394 {
392 DtoDeclareFunction(fdecl); 395 DtoDeclareFunction(fdecl);
393 } 396 }
394 } 397 }
395 398