Skip to content

Commit 2791373

Browse files
committed
Fixes issue #703.
The function declaration fd may be null on an indirect call.
1 parent df0d302 commit 2791373

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dmd2/expression.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -1695,7 +1695,7 @@ Type *functionParameters(Loc loc, Scope *sc, TypeFunction *tf,
16951695
// If not D linkage, do promotions
16961696
#if IN_LLVM
16971697
// LDC: don't do promotions on intrinsics
1698-
if (tf->linkage != LINKd && fd->llvmInternal != LLVMintrinsic)
1698+
if (tf->linkage != LINKd && (!fd || fd->llvmInternal != LLVMintrinsic))
16991699
#else
17001700
if (tf->linkage != LINKd)
17011701
#endif

0 commit comments

Comments
 (0)