diff --git a/IDEHelper/Compiler/BfModule.cpp b/IDEHelper/Compiler/BfModule.cpp index 4706b8e0..d5eae435 100644 --- a/IDEHelper/Compiler/BfModule.cpp +++ b/IDEHelper/Compiler/BfModule.cpp @@ -18155,7 +18155,7 @@ void BfModule::ProcessMethod(BfMethodInstance* methodInstance, bool isInlineDup) { // If we hot swap, we want to make sure at least one method refers to this extern method so it gets pulled in // incase it gets called later by some hot-loaded coded - if (mCompiler->mOptions.mAllowHotSwapping) + if ((mCompiler->mOptions.mAllowHotSwapping) && (mCurMethodInstance->mIRFunction) && (!mCurMethodInstance->mIRFunction.IsFake())) CreateFakeCallerMethod(mangledName); mBfIRBuilder->Func_DeleteBody(mCurMethodInstance->mIRFunction); }