mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-20 00:50:25 +02:00
Fixed issues using object flags on on-debug default alloc
This commit is contained in:
parent
66216ce5d9
commit
63c6421413
8 changed files with 50 additions and 12 deletions
|
@ -589,9 +589,10 @@ namespace IDE.Compiler
|
|||
SetOpt(options.mEmitDynamicCastCheck, .EmitDynamicCastCheck);
|
||||
SetOpt(enableObjectDebugFlags, .EnableObjectDebugFlags);
|
||||
SetOpt(emitObjectAccessCheck, .EmitObjectAccessCheck);
|
||||
#if BF_PLATFORM_WINDOWS
|
||||
SetOpt(options.mEnableRealtimeLeakCheck, .EnableRealtimeLeakCheck);
|
||||
#endif
|
||||
|
||||
if (options.LeakCheckingEnabled)
|
||||
SetOpt(options.mEnableRealtimeLeakCheck, .EnableRealtimeLeakCheck);
|
||||
|
||||
SetOpt(options.mEnableSideStack, .EnableSideStack);
|
||||
#if !CLI
|
||||
SetOpt(options.mAllowHotSwapping, .EnableHotSwapping);
|
||||
|
|
|
@ -7180,13 +7180,12 @@ namespace IDE
|
|||
|
||||
// Only supported on Windows at the moment
|
||||
bool hasLeakCheck = false;
|
||||
#if BF_PLATFORM_WINDOWS
|
||||
if (workspaceOptions.mEnableRealtimeLeakCheck && workspaceOptions.mEnableObjectDebugFlags)
|
||||
if (workspaceOptions.LeakCheckingEnabled)
|
||||
{
|
||||
hasLeakCheck = true;
|
||||
macroList.Add("BF_ENABLE_REALTIME_LEAK_CHECK");
|
||||
}
|
||||
#endif
|
||||
|
||||
if ((workspaceOptions.mAllocType == .Debug) || (hasLeakCheck))
|
||||
macroList.Add("BF_DEBUG_ALLOC");
|
||||
|
||||
|
|
|
@ -245,6 +245,18 @@ namespace IDE
|
|||
delete configSel;
|
||||
}
|
||||
|
||||
public bool LeakCheckingEnabled
|
||||
{
|
||||
get
|
||||
{
|
||||
#if BF_PLATFORM_WINDOWS
|
||||
return mEnableRealtimeLeakCheck && mEnableObjectDebugFlags && (mAllocType == .Debug);
|
||||
#else
|
||||
return false;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
public bool IsTestProject(Project project)
|
||||
{
|
||||
return ((mBuildKind == .Test) &&
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue