mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-01-27 10:03:13 +01:00
Always emit a stop point for return statements - even for void returns.
This commit is contained in:
@@ -53,6 +53,9 @@ void ReturnStatement::toIR(IRState* p)
|
||||
Logger::println("ReturnStatement::toIR(): %s", loc.toChars());
|
||||
LOG_SCOPE;
|
||||
|
||||
if (global.params.symdebug)
|
||||
DtoDwarfStopPoint(loc.linnum);
|
||||
|
||||
// is there a return value expression?
|
||||
if (exp)
|
||||
{
|
||||
@@ -64,9 +67,6 @@ void ReturnStatement::toIR(IRState* p)
|
||||
IrFunction* f = p->func();
|
||||
assert(f->decl->ir.irFunc->retArg);
|
||||
|
||||
// emit dbg line
|
||||
if (global.params.symdebug) DtoDwarfStopPoint(loc.linnum);
|
||||
|
||||
// FIXME: is there ever a case where a sret return needs to be rewritten for the ABI?
|
||||
|
||||
// get return pointer
|
||||
@@ -88,8 +88,6 @@ void ReturnStatement::toIR(IRState* p)
|
||||
// the return type is not void, so this is a normal "register" return
|
||||
else
|
||||
{
|
||||
if (global.params.symdebug) DtoDwarfStopPoint(loc.linnum);
|
||||
|
||||
// do abi specific transformations on the return value
|
||||
LLValue* v = p->func()->type->fty.putRet(exp->type, exp->toElem(p));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user