mirror of
https://github.com/beefytech/Beef.git
synced 2025-06-10 12:32:20 +02:00
Bug fixes, installer, [Export]
Fixed a bunch of bugs in aggregate const initializers Fixed ZIP bugs Fixed a compilation case where we change protection while reifying a type Added another project kind - Dynamic Library Added [Export] for DLL method exporting Fixed some issues of things being generated as __NOINLINE incorrectly Fixed an issue with module extensions with not-yet-demanded on-demand methods Started adding Installer
This commit is contained in:
parent
efa22e51fb
commit
09016c8dc0
135 changed files with 3615 additions and 2337 deletions
|
@ -27,7 +27,7 @@ TargetDirectory = "$(WorkspaceDir)/dist"
|
|||
TargetName = "BeefIDE_d"
|
||||
OtherLinkFlags = "$(LinkFlags) Comdlg32.lib kernel32.lib user32.lib advapi32.lib shell32.lib IDEHelper64_d.lib BeefySysLib64_d.lib"
|
||||
CLibType = "Dynamic"
|
||||
DebugCommandArguments = "-proddir=C:\\Beef\\BeefTools\\BeefInstall"
|
||||
DebugCommandArguments = "-open=c:\\proj\\TestCPP\\TestCPP.bfdbg"
|
||||
DebugWorkingDirectory = "c:\\Beef\\IDE\\Tests\\EmptyTest"
|
||||
EnvironmentVars = ["_NO_DEBUG_HEAP=1"]
|
||||
|
||||
|
|
|
@ -1,13 +1,14 @@
|
|||
FileVersion = 1
|
||||
LastConfig = "Debug"
|
||||
LastPlatform = "Win64"
|
||||
RecentFilesList = ["c:\\beef\\ide\\src\\util\\Zip.bf", "c:\\beef\\ide\\src\\ui\\AutoComplete.bf"]
|
||||
RecentFilesList = ["c:\\beef\\ide\\src\\IDEApp.bf", "c:\\beef\\IDEHelper\\DebugManager.cpp", "c:\\beef\\IDEHelper\\Compiler\\BfModule.cpp", "c:\\beef\\IDEHelper\\Compiler\\BfCompiler.cpp", "c:\\beef\\ide\\src\\BuildContext.bf", "c:\\beef\\beefrt\\dbg\\gc.cpp", "c:\\beef\\ide\\src\\ScriptManager.bf", "c:\\beef\\ide\\src\\Project.bf", "c:\\beef\\ide\\src\\CommandQueueManager.bf", "c:\\Beef\\BeefLibs\\corlib\\src\\System\\String.bf"]
|
||||
StepFilters = ["System.StringView.operator System.StringView"]
|
||||
|
||||
[MainWindow]
|
||||
X = 679
|
||||
Y = 504
|
||||
Width = 2487
|
||||
Height = 1554
|
||||
X = 1021
|
||||
Y = 227
|
||||
Width = 2206
|
||||
Height = 1810
|
||||
|
||||
[MainDockingFrame]
|
||||
Type = "DockingFrame"
|
||||
|
@ -41,39 +42,346 @@ DefaultDocumentsTabbedView = true
|
|||
Type = "TabbedView"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
Active = true
|
||||
TabLabel = "Zip.bf"
|
||||
TabWidth = 73.0
|
||||
TabLabel = "DebugManager.cpp"
|
||||
TabWidth = 156.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\util\\Zip.bf"
|
||||
CursorPos = 2802
|
||||
VertPos = 780.0
|
||||
FilePath = "c:\\beef\\IDEHelper\\DebugManager.cpp"
|
||||
CursorPos = 15042
|
||||
VertPos = 8490.0
|
||||
ProjectName = "IDEHelper"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "CommandQueueManager.bf"
|
||||
TabWidth = 205.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\CommandQueueManager.bf"
|
||||
CursorPos = 896
|
||||
VertPos = 1170.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "ProjectProperties.bf"
|
||||
TabWidth = 145.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\ProjectProperties.bf"
|
||||
CursorPos = 1930
|
||||
VertPos = 270.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "ProjectPanel.bf"
|
||||
TabWidth = 116.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\ProjectPanel.bf"
|
||||
CursorPos = 58964
|
||||
VertPos = 25350.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Directory.bf"
|
||||
TabWidth = 98.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\BeefLibs\\corlib\\src\\System\\IO\\Directory.bf"
|
||||
CursorPos = 294
|
||||
ProjectName = "corlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "AutoComplete.bf"
|
||||
TabWidth = 138.0
|
||||
TabWidth = 128.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\AutoComplete.bf"
|
||||
CursorPos = 3588
|
||||
VertPos = 2205.0
|
||||
CursorPos = 5948
|
||||
VertPos = 3060.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Disassembly"
|
||||
TabWidth = 122.0
|
||||
Type = "DisassemblyPanel"
|
||||
TabLabel = "Stopwatch.bf"
|
||||
TabWidth = 105.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\BeefLibs\\corlib\\src\\System\\Diagnostics\\Stopwatch.bf"
|
||||
CursorPos = 309
|
||||
ProjectName = "corlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "IComparable.bf"
|
||||
TabWidth = 120.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\BeefLibs\\corlib\\src\\System\\IComparable.bf"
|
||||
CursorPos = 404
|
||||
ProjectName = "corlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Dictionary.bf"
|
||||
TabWidth = 103.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\BeefLibs\\corlib\\src\\System\\Collections\\Generic\\Dictionary.bf"
|
||||
CursorPos = 13141
|
||||
ProjectName = "corlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Workspace.bf"
|
||||
TabWidth = 110.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\Workspace.bf"
|
||||
CursorPos = 10820
|
||||
VertPos = 5745.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Project.bf"
|
||||
TabWidth = 85.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\Project.bf"
|
||||
CursorPos = 31286
|
||||
VertPos = 16875.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "gc.cpp"
|
||||
TabWidth = 69.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\beefrt\\dbg\\gc.cpp"
|
||||
CursorPos = 29571
|
||||
VertPos = 16845.0
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "String.bf"
|
||||
TabWidth = 79.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\BeefLibs\\corlib\\src\\System\\String.bf"
|
||||
CursorPos = 20322
|
||||
VertPos = 11775.0
|
||||
ProjectName = "corlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "ImmediatePanel.bf"
|
||||
TabWidth = 137.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\ImmediatePanel.bf"
|
||||
CursorPos = 1248
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "StatusBar.bf"
|
||||
TabWidth = 98.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\StatusBar.bf"
|
||||
CursorPos = 11876
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "ImmediateWidget.bf"
|
||||
TabWidth = 148.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\ImmediateWidget.bf"
|
||||
CursorPos = 10575
|
||||
VertPos = 4425.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "ScriptManager.bf"
|
||||
TabWidth = 130.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ScriptManager.bf"
|
||||
CursorPos = 46372
|
||||
VertPos = 29080.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "ListView.bf"
|
||||
TabWidth = 91.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\BeefLibs\\Beefy2D\\src\\widgets\\ListView.bf"
|
||||
CursorPos = 24610
|
||||
ProjectName = "Beefy2D"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "EditWidget.bf"
|
||||
TabWidth = 109.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\BeefLibs\\Beefy2D\\src\\widgets\\EditWidget.bf"
|
||||
CursorPos = 70859
|
||||
ProjectName = "Beefy2D"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "OpenFileInSolutionDialog.bf"
|
||||
TabWidth = 191.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\OpenFileInSolutionDialog.bf"
|
||||
CursorPos = 3378
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "InstalledProjectDialog.bf"
|
||||
TabWidth = 171.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\InstalledProjectDialog.bf"
|
||||
CursorPos = 2662
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "ClassViewPanel.bf"
|
||||
TabWidth = 133.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\ClassViewPanel.bf"
|
||||
CursorPos = 10536
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "BinaryDataWidget.bf"
|
||||
TabWidth = 149.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\ui\\BinaryDataWidget.bf"
|
||||
CursorPos = 87580
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "BfIRBuilder.cpp"
|
||||
TabWidth = 116.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\IDEHelper\\Compiler\\BfIRBuilder.cpp"
|
||||
CursorPos = 132547
|
||||
ProjectName = "IDEHelper"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "BfIRCodeGen.cpp"
|
||||
TabWidth = 131.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\IDEHelper\\Compiler\\BfIRCodeGen.cpp"
|
||||
CursorPos = 124783
|
||||
ProjectName = "IDEHelper"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "memory"
|
||||
TabWidth = 78.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Professional\\VC\\Tools\\MSVC\\14.21.27702\\include\\memory"
|
||||
CursorPos = 68115
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Verifier.cpp"
|
||||
TabWidth = 96.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\extern\\llvm-project_8_0_0\\llvm\\lib\\IR\\Verifier.cpp"
|
||||
CursorPos = 189261
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "BfExprEvaluator.cpp"
|
||||
TabWidth = 145.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\IDEHelper\\Compiler\\BfExprEvaluator.cpp"
|
||||
CursorPos = 395532
|
||||
ProjectName = "IDEHelper"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "BfModule.cpp"
|
||||
TabWidth = 111.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\IDEHelper\\Compiler\\BfModule.cpp"
|
||||
CursorPos = 701696
|
||||
VertPos = 303765.0
|
||||
ProjectName = "IDEHelper"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Result.bf"
|
||||
TabWidth = 80.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\BeefLibs\\corlib\\src\\System\\Result.bf"
|
||||
CursorPos = 699
|
||||
ProjectName = "corlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "LegacyPassManager.cpp"
|
||||
TabWidth = 173.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\extern\\llvm-project_8_0_0\\llvm\\lib\\IR\\LegacyPassManager.cpp"
|
||||
CursorPos = 56552
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "LexicalScopes.cpp"
|
||||
TabWidth = 135.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\extern\\llvm-project_8_0_0\\llvm\\lib\\CodeGen\\LexicalScopes.cpp"
|
||||
CursorPos = 6263
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "TimeZoneInfo.bf"
|
||||
TabWidth = 124.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\BeefLibs\\corlib\\src\\System\\TimeZoneInfo.bf"
|
||||
CursorPos = 118021
|
||||
ProjectName = "corlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Windows.bf"
|
||||
TabWidth = 98.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\Beef\\BeefLibs\\corlib\\src\\System\\Windows.bf"
|
||||
CursorPos = 40234
|
||||
ProjectName = "corlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Platform.cpp"
|
||||
TabWidth = 104.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\BeefySysLib\\platform\\win\\Platform.cpp"
|
||||
CursorPos = 59719
|
||||
ProjectName = "BeefySysLib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "BfCompiler.bf"
|
||||
TabWidth = 108.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\Compiler\\BfCompiler.bf"
|
||||
CursorPos = 7397
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "BfCompiler.cpp"
|
||||
TabWidth = 118.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\IDEHelper\\Compiler\\BfCompiler.cpp"
|
||||
CursorPos = 181147
|
||||
VertPos = 82605.0
|
||||
ProjectName = "IDEHelper"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "WinDebugger.cpp"
|
||||
TabWidth = 135.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\IDEHelper\\WinDebugger.cpp"
|
||||
CursorPos = 120268
|
||||
ProjectName = "Debugger64"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "BuildContext.bf"
|
||||
TabWidth = 117.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\BuildContext.bf"
|
||||
CursorPos = 3642
|
||||
VertPos = 1395.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
Active = true
|
||||
TabLabel = "IDEApp.bf"
|
||||
TabWidth = 88.0
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\src\\IDEApp.bf"
|
||||
CursorPos = 320852
|
||||
VertPos = 158655.0
|
||||
ProjectName = "IDE"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets]]
|
||||
RequestedWidth = 250.0
|
||||
RequestedHeight = 553.0
|
||||
RequestedHeight = 408.0
|
||||
Type = "DockingFrame"
|
||||
SplitType = 1
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets]]
|
||||
RequestedWidth = 250.0
|
||||
RequestedHeight = 250.0
|
||||
SizePriority = 0.443346
|
||||
SizePriority = 0.4483547
|
||||
Type = "TabbedView"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
|
@ -99,7 +407,7 @@ TabLabel = "Watch"
|
|||
TabWidth = 86.0
|
||||
Type = "WatchPanel"
|
||||
Columns = [{Width = 306.0}, {Width = 675.0}, {Width = 200.0}]
|
||||
Items = [""]
|
||||
Items = ["this", "instIdx", "mcBlock", "bfProject", "gApp", ""]
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Auto"
|
||||
|
@ -110,7 +418,7 @@ Columns = [{Width = 200.0}, {Width = 442.0}, {Width = 200.0}]
|
|||
[[MainDockingFrame.DockedWidgets.DockedWidgets]]
|
||||
RequestedWidth = 910.0
|
||||
RequestedHeight = 793.0
|
||||
SizePriority = 0.203422
|
||||
SizePriority = 0.1984133
|
||||
Type = "TabbedView"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
|
@ -146,6 +454,31 @@ TabLabel = "Output"
|
|||
TabWidth = 90.0
|
||||
Type = "OutputPanel"
|
||||
|
||||
[[Breakpoints]]
|
||||
File = "c:\\Beef\\extern\\llvm-project_8_0_0\\llvm\\lib\\IR\\Verifier.cpp"
|
||||
Line = 4875
|
||||
Column = 6
|
||||
|
||||
[[Breakpoints]]
|
||||
File = "c:\\Beef\\extern\\llvm-project_8_0_0\\llvm\\lib\\IR\\Verifier.cpp"
|
||||
Line = 214
|
||||
Column = 4
|
||||
|
||||
[[Breakpoints]]
|
||||
File = "c:\\beef\\ide\\src\\Workspace.bf"
|
||||
Line = 661
|
||||
Column = 3
|
||||
|
||||
[[Bookmarks]]
|
||||
File = "c:\\beef\\ide\\src\\BuildContext.bf"
|
||||
Line = 465
|
||||
Column = 6
|
||||
|
||||
[[Bookmarks]]
|
||||
File = "c:\\beef\\ide\\src\\BuildContext.bf"
|
||||
Line = 465
|
||||
Column = 6
|
||||
|
||||
[DebuggerDisplayTypes.""]
|
||||
IntDisplayType = "Default"
|
||||
IntDisplayType = "Hexadecimal"
|
||||
MmDisplayType = "Default"
|
||||
|
|
5
IDE/Tests/BugW001/BeefProj.toml
Normal file
5
IDE/Tests/BugW001/BeefProj.toml
Normal file
|
@ -0,0 +1,5 @@
|
|||
FileVersion = 1
|
||||
|
||||
[Project]
|
||||
Name = "BugW001"
|
||||
StartupObject = "BugW001.Program"
|
8
IDE/Tests/BugW001/BeefSpace.toml
Normal file
8
IDE/Tests/BugW001/BeefSpace.toml
Normal file
|
@ -0,0 +1,8 @@
|
|||
FileVersion = 1
|
||||
Projects = {BugW001 = {Path = "."}}
|
||||
|
||||
[Workspace]
|
||||
StartupProject = "BugW001"
|
||||
|
||||
[Configs.Debug.Win64]
|
||||
BfOptimizationLevel = "O0"
|
9
IDE/Tests/BugW001/scripts/Test.txt
Normal file
9
IDE/Tests/BugW001/scripts/Test.txt
Normal file
|
@ -0,0 +1,9 @@
|
|||
# This tests extensions on Result<void*>, where the void* operator would be double-declared in the IR
|
||||
|
||||
ShowFile("src/Program.bf")
|
||||
GotoText("//Main_Start")
|
||||
ToggleBreakpoint()
|
||||
RunWithCompiling()
|
||||
|
||||
ToggleCommentAt("Result_Get")
|
||||
Compile()
|
18
IDE/Tests/BugW001/src/Program.bf
Normal file
18
IDE/Tests/BugW001/src/Program.bf
Normal file
|
@ -0,0 +1,18 @@
|
|||
#pragma warning disable 168
|
||||
|
||||
using System;
|
||||
|
||||
namespace BugW001
|
||||
{
|
||||
class Program
|
||||
{
|
||||
static void Main()
|
||||
{
|
||||
//Main_Start
|
||||
Result<void*> result = .();
|
||||
/*Result_Get
|
||||
void* vp = result;
|
||||
*/
|
||||
}
|
||||
}
|
||||
}
|
|
@ -10,6 +10,7 @@ IntermediateType = "ObjectAndIRCode"
|
|||
ConfigSelections = {mintest2 = {Enabled = false}}
|
||||
|
||||
[Configs.Debug.Win64]
|
||||
BfOptimizationLevel = "O0"
|
||||
IntermediateType = "ObjectAndIRCode"
|
||||
COptimizationLevel = "Og"
|
||||
|
||||
|
|
|
@ -291,33 +291,6 @@ namespace System
|
|||
public bool Profile;
|
||||
}
|
||||
|
||||
namespace Runtime.InteropServices
|
||||
{
|
||||
public enum CallingConvention
|
||||
{
|
||||
Winapi = 1,
|
||||
Cdecl = 2,
|
||||
StdCall = 3,
|
||||
ThisCall = 4,
|
||||
FastCall = 5,
|
||||
|
||||
Default = Cdecl
|
||||
}
|
||||
|
||||
[AttributeUsage(AttributeTargets.Method /*3*/)]
|
||||
public struct DllImportAttribute : Attribute
|
||||
{
|
||||
public this(String dllName)
|
||||
{
|
||||
CallingConvention = .Default;
|
||||
CLink = false;
|
||||
}
|
||||
|
||||
public CallingConvention CallingConvention;
|
||||
public bool CLink;
|
||||
}
|
||||
}
|
||||
|
||||
public struct ImportAttribute : Attribute
|
||||
{
|
||||
public this(String libName)
|
||||
|
@ -325,6 +298,11 @@ namespace System
|
|||
}
|
||||
}
|
||||
|
||||
public struct ExportAttribute : Attribute
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
[AttributeUsage(AttributeTargets.StaticField | AttributeTargets.Field, .NotInherited)]
|
||||
public struct ThreadStaticAttribute : Attribute
|
||||
{
|
||||
|
|
|
@ -7,7 +7,6 @@
|
|||
#endif
|
||||
|
||||
using System;
|
||||
using System.Runtime;
|
||||
using System.Diagnostics;
|
||||
using System.Diagnostics.Contracts;
|
||||
using System.Threading;
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace System.Collections
|
||||
{
|
||||
|
|
|
@ -19,7 +19,6 @@ namespace System
|
|||
///#if GENERICS_WORK
|
||||
/// using System.Numerics;
|
||||
///#endif
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics.Contracts;
|
||||
|
||||
public struct Double : double, IHashable, IOpComparable, IOpNegatable, ICanBeNaN /*: IComparable, IFormattable, IConvertible
|
||||
|
|
|
@ -16,7 +16,6 @@ namespace System
|
|||
{
|
||||
//This class contains only static members and doesn't require serialization.
|
||||
using System;
|
||||
using System.Runtime;
|
||||
using System.Diagnostics.Contracts;
|
||||
using System.Diagnostics;
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
using System.Reflection;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace System
|
||||
|
|
|
@ -20,7 +20,6 @@
|
|||
namespace System.Threading
|
||||
{
|
||||
using System;
|
||||
using System.Runtime;
|
||||
using System.Threading;
|
||||
using System.Diagnostics.Contracts;
|
||||
using System.Diagnostics;
|
||||
|
|
|
@ -1,387 +0,0 @@
|
|||
LastConfig = "Debug"
|
||||
LastPlatform = "Win64"
|
||||
RecentFilesList = ["c:\\beef\\ide\\mintest\\src\\main2.cs", "c:\\beef\\ide\\mintest\\src\\main3.cs", "c:\\beef\\ide\\mintest\\src\\main.cs", "c:\\beef\\ide\\mintest\\minlib\\src\\System\\String.cs", "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Collections\\Generic\\List.bf", "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Array.cs", "c:\\beef\\ide\\mintest\\minlib\\src\\System\\IComparable.cs", "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Collections\\Generic\\Dictionary.bf", "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Object.cs", "Disassembly"]
|
||||
|
||||
[MainWindow]
|
||||
X = 128
|
||||
Y = 166
|
||||
Width = 2434
|
||||
Height = 1847
|
||||
|
||||
[MainDockingFrame]
|
||||
Type = "DockingFrame"
|
||||
SplitType = 2
|
||||
|
||||
[[MainDockingFrame.DockedWidgets]]
|
||||
RequestedWidth = 250.000000
|
||||
RequestedHeight = 1133.000000
|
||||
SizePriority = 1133.000000
|
||||
Type = "DockingFrame"
|
||||
SplitType = 1
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets]]
|
||||
RequestedWidth = 263.000000
|
||||
RequestedHeight = 250.000000
|
||||
SizePriority = 0.000000
|
||||
Type = "TabbedView"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Workspace"
|
||||
TabWidth = 95.000000
|
||||
Type = "ProjectPanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets]]
|
||||
IsFillWidget = true
|
||||
RequestedWidth = 1639.000000
|
||||
RequestedHeight = 150.000000
|
||||
SizePriority = 1639.000000
|
||||
DefaultDocumentsTabbedView = true
|
||||
Type = "TabbedView"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Contracts.cs"
|
||||
TabWidth = 110.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Diagnostics\\Contracts\\Contracts.cs"
|
||||
CursorPos = 2270
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "internal.cpp"
|
||||
TabWidth = 108.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\beefrt\\rt\\internal.cpp"
|
||||
CursorPos = 20281
|
||||
VertPos = 0.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "main4.cs"
|
||||
TabWidth = 90.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\mintest2\\src\\main4.cs"
|
||||
CursorPos = 182
|
||||
VertPos = 0.000000
|
||||
ProjectName = "mintest2"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Internal.cs"
|
||||
TabWidth = 98.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Internal.cs"
|
||||
CursorPos = 2881
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Array.cs"
|
||||
TabWidth = 86.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Array.cs"
|
||||
CursorPos = 608
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Variant.cs"
|
||||
TabWidth = 96.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Variant.cs"
|
||||
CursorPos = 4292
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "String.cs"
|
||||
TabWidth = 89.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\String.cs"
|
||||
CursorPos = 10914
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Runtime.bf"
|
||||
TabWidth = 102.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Runtime.bf"
|
||||
CursorPos = 2021
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "List.bf"
|
||||
TabWidth = 74.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Collections\\Generic\\List.bf"
|
||||
CursorPos = 9410
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Event.bf"
|
||||
TabWidth = 86.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Event.bf"
|
||||
CursorPos = 743
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "IEnumerator.cs"
|
||||
TabWidth = 125.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Collections\\IEnumerator.cs"
|
||||
CursorPos = 464
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Type.cs"
|
||||
TabWidth = 83.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Type.cs"
|
||||
CursorPos = 1538
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Disassembly"
|
||||
TabWidth = 112.000000
|
||||
Type = "DisassemblyPanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Object.cs"
|
||||
TabWidth = 93.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Object.cs"
|
||||
CursorPos = 452
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "main2.cs"
|
||||
TabWidth = 90.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\src\\main2.cs"
|
||||
CursorPos = 2845
|
||||
VertPos = 3060.000000
|
||||
ProjectName = "mintest"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "main3.cs"
|
||||
TabWidth = 90.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\src\\main3.cs"
|
||||
CursorPos = 1954
|
||||
VertPos = 0.000000
|
||||
ProjectName = "mintest"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "main.cs"
|
||||
TabWidth = 83.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\src\\main.cs"
|
||||
CursorPos = 4383
|
||||
VertPos = 0.000000
|
||||
ProjectName = "mintest"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Nullable.cs"
|
||||
TabWidth = 103.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Nullable.cs"
|
||||
CursorPos = 623
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "GC.cs"
|
||||
TabWidth = 72.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\GC.cs"
|
||||
CursorPos = 1934
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "testdll.cpp"
|
||||
TabWidth = 100.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\beeftools\\testdll\\testdll.cpp"
|
||||
CursorPos = 939
|
||||
VertPos = 0.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "stdio.h"
|
||||
TabWidth = 79.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\program files (x86)\\windows kits\\10\\include\\10.0.16299.0\\ucrt\\stdio.h"
|
||||
CursorPos = 27765
|
||||
VertPos = 0.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Profiler.bf"
|
||||
TabWidth = 96.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Diagnostics\\Profiler.bf"
|
||||
CursorPos = 450
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Dictionary.bf"
|
||||
TabWidth = 113.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\Collections\\Generic\\Dictionary.bf"
|
||||
CursorPos = 3575
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "IComparable.cs"
|
||||
TabWidth = 130.000000
|
||||
Type = "SourceViewPanel"
|
||||
FilePath = "c:\\beef\\ide\\mintest\\minlib\\src\\System\\IComparable.cs"
|
||||
CursorPos = 75
|
||||
VertPos = 0.000000
|
||||
ProjectName = "minlib"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets]]
|
||||
RequestedWidth = 291.000000
|
||||
RequestedHeight = 250.000000
|
||||
SizePriority = 0.000000
|
||||
Type = "TabbedView"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Properties"
|
||||
TabWidth = 90.000000
|
||||
Type = "PropertiesPanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets]]
|
||||
RequestedWidth = 250.000000
|
||||
RequestedHeight = 540.000000
|
||||
SizePriority = 0.000000
|
||||
Type = "DockingFrame"
|
||||
SplitType = 1
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets]]
|
||||
RequestedWidth = 920.000000
|
||||
RequestedHeight = 250.000000
|
||||
SizePriority = 0.396523
|
||||
Type = "TabbedView"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Auto"
|
||||
TabWidth = 150.000000
|
||||
Type = "AutoWatchPanel"
|
||||
Items = ["args", "str", ""]
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs.Columns]]
|
||||
Width = 225.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs.Columns]]
|
||||
Width = 498.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs.Columns]]
|
||||
Width = 275.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Watch"
|
||||
TabWidth = 150.000000
|
||||
Type = "WatchPanel"
|
||||
Items = ["args", "z", ""]
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs.Columns]]
|
||||
Width = 264.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs.Columns]]
|
||||
Width = 984.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs.Columns]]
|
||||
Width = 275.000000
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Memory"
|
||||
TabWidth = 150.000000
|
||||
Type = "MemoryPanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Breakpoints"
|
||||
TabWidth = 150.000000
|
||||
Type = "BreakpointPanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets]]
|
||||
RequestedWidth = 777.000000
|
||||
RequestedHeight = 250.000000
|
||||
SizePriority = 0.603477
|
||||
Type = "TabbedView"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Threads"
|
||||
TabWidth = 150.000000
|
||||
Type = "ThreadPanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Immediate"
|
||||
TabWidth = 150.000000
|
||||
Type = "ImmediatePanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Output"
|
||||
TabWidth = 150.000000
|
||||
Type = "OutputPanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Find Results"
|
||||
TabWidth = 150.000000
|
||||
Type = "FindResultsPanel"
|
||||
|
||||
[[MainDockingFrame.DockedWidgets.DockedWidgets.Tabs]]
|
||||
TabLabel = "Call Stack"
|
||||
TabWidth = 150.000000
|
||||
Type = "CallStackPanel"
|
||||
|
||||
[[Bookmarks]]
|
||||
File = "c:\\beef\\IDE\\mintest\\main.cs"
|
||||
Line = 306
|
||||
Column = 3
|
||||
|
||||
[[Bookmarks]]
|
||||
File = "c:\\beef\\IDE\\mintest\\main.cs"
|
||||
Line = 56
|
||||
Column = 2
|
||||
|
||||
[[Bookmarks]]
|
||||
File = "c:\\beef\\IDE\\mintest\\main2.cs"
|
||||
Line = 8
|
||||
Column = 0
|
||||
|
||||
[[Bookmarks]]
|
||||
File = "c:\\beef\\IDE\\mintest\\main3.cs"
|
||||
Line = 177
|
||||
Column = 2
|
||||
|
||||
[DebuggerDisplayTypes]
|
||||
|
||||
[DebuggerDisplayTypes.""]
|
||||
IntDisplayType = "Hexadecimal"
|
||||
MmDisplayType = "Default"
|
||||
|
||||
[[StepFilters]]
|
||||
Filter = "System::Internal::ThrowIndexOutOfRange"
|
||||
|
||||
[[StepFilters]]
|
||||
Filter = "BfObjectStackInit"
|
||||
|
||||
[[StepFilters]]
|
||||
Filter = "[].this"
|
||||
|
||||
[[StepFilters]]
|
||||
Filter = "std::basic_string<>::basic_string<>"
|
||||
|
||||
[[StepFilters]]
|
||||
Filter = "System.StringView.this"
|
||||
|
||||
[[StepFilters]]
|
||||
Filter = "TestA::TestA"
|
|
@ -15,7 +15,6 @@ using System;
|
|||
using System.Threading;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections;
|
||||
|
@ -178,13 +177,18 @@ namespace Hey.Dude.Bro
|
|||
|
||||
public static int Main(String[] args)
|
||||
{
|
||||
while (true)
|
||||
Blurg.Hey();
|
||||
|
||||
/*while (true)
|
||||
{
|
||||
int a = 0;
|
||||
}
|
||||
|
||||
int* iPtr = null;
|
||||
*iPtr = 123;
|
||||
*iPtr = 123;*/
|
||||
|
||||
GC.SetAutoCollectPeriod(20);
|
||||
Thread.Sleep(1000);
|
||||
|
||||
String str = scope .("Boops!");
|
||||
int len = str.GetLength();
|
||||
|
@ -196,7 +200,7 @@ namespace Hey.Dude.Bro
|
|||
|
||||
//Thread.Sleep(500);
|
||||
|
||||
Test2(1, 2, 3, 4);
|
||||
//Test2(1, 2, 3, 4);
|
||||
|
||||
thread.Join();
|
||||
|
||||
|
|
|
@ -0,0 +1,7 @@
|
|||
class Snorf
|
||||
{
|
||||
struct Bloog
|
||||
{
|
||||
int mA;
|
||||
}
|
||||
}
|
|
@ -80,13 +80,6 @@ class ClassF : ClassE
|
|||
|
||||
}
|
||||
|
||||
class Snorf
|
||||
{
|
||||
public static void Borf(ClassD cd)
|
||||
{
|
||||
cd.Poo();
|
||||
}
|
||||
}
|
||||
|
||||
[NoDiscard("Use this value!")]
|
||||
struct TestStruct
|
||||
|
@ -97,70 +90,33 @@ struct TestStruct
|
|||
|
||||
class Blurg
|
||||
{
|
||||
public static void UseTS(TestStruct ts)
|
||||
[Export, CLink, StdCall]
|
||||
public static void Poof()
|
||||
{
|
||||
int c = ts.mA;
|
||||
PrintF("Poofs!\n");
|
||||
}
|
||||
|
||||
[NoDiscard("Why you no use me?")]
|
||||
public static int UseMe()
|
||||
[Export, CLink, StdCall]
|
||||
public static void Poof2()
|
||||
{
|
||||
return 999;
|
||||
}
|
||||
|
||||
public static TestStruct UseIt()
|
||||
{
|
||||
return .();
|
||||
}
|
||||
|
||||
mixin FartOut(int a)
|
||||
{
|
||||
a = 0;
|
||||
|
||||
//let c = 1;
|
||||
//c = 3;
|
||||
//int b = 123;
|
||||
//int c = 99;
|
||||
PrintF("Poofs2!\n");
|
||||
}
|
||||
|
||||
public static void Hey()
|
||||
{
|
||||
mixin Fart(int a)
|
||||
{
|
||||
//a = 0;
|
||||
//int b = 123;
|
||||
//int c = 99;
|
||||
}
|
||||
Snorf sn = scope .();
|
||||
|
||||
/*int c = 222;
|
||||
Fart!(c);*/
|
||||
Result<void*> voidPtrResult = default;
|
||||
|
||||
//int __CRASH_AUTOVARIABLE__ = 123;
|
||||
|
||||
//UseIt();
|
||||
|
||||
//UseMe();
|
||||
|
||||
//int a;
|
||||
//void* val = voidPtrResult;
|
||||
|
||||
|
||||
for (int i < 10)
|
||||
{
|
||||
int a = 0;
|
||||
}
|
||||
//Result<TestStruct> ts = .Ok(.());
|
||||
|
||||
TestStruct ts = .();
|
||||
ts.mA = 111;
|
||||
ts.mB = 222;
|
||||
UseTS(ts);
|
||||
//let val = ts.Get();
|
||||
//Snorf.Bloog bl = .();
|
||||
|
||||
ClassD cd = null;
|
||||
//let str = cd.mStr;
|
||||
|
||||
|
||||
#if A || B
|
||||
ClassC cc = scope .();
|
||||
#endif
|
||||
//Poof();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
1062
IDE/src/BuildContext.bf
Normal file
1062
IDE/src/BuildContext.bf
Normal file
File diff suppressed because it is too large
Load diff
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using Beefy.widgets;
|
||||
|
|
|
@ -5,7 +5,6 @@ using System.Collections.Generic;
|
|||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using Beefy.widgets;
|
||||
using IDE.Compiler;
|
||||
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Threading;
|
||||
using System.Diagnostics;
|
||||
using Beefy.widgets;
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics;
|
||||
using Beefy.widgets;
|
||||
using Beefy.utils;
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using Beefy.utils;
|
||||
using System.Diagnostics;
|
||||
using System.Threading;
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace IDE.Compiler
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace IDE.Compiler
|
||||
{
|
||||
|
|
|
@ -3,7 +3,6 @@ using System.Collections.Generic;
|
|||
using System.Text;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics;
|
||||
|
||||
namespace IDE.Compiler
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using Beefy.gfx;
|
||||
using Beefy.theme.dark;
|
||||
using System.IO;
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
using System;
|
||||
using System.Runtime.InteropServices;
|
||||
using IDE;
|
||||
|
||||
namespace Debugger
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics;
|
||||
using Beefy.utils;
|
||||
using IDE.util;
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Diagnostics;
|
||||
using Beefy.utils;
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
|
|
1136
IDE/src/IDEApp.bf
1136
IDE/src/IDEApp.bf
File diff suppressed because it is too large
Load diff
|
@ -5,7 +5,6 @@ using System.Threading.Tasks;
|
|||
using System.IO;
|
||||
using Beefy.widgets;
|
||||
using Beefy.utils;
|
||||
using System.Runtime.InteropServices;
|
||||
using Beefy;
|
||||
using Beefy.gfx;
|
||||
using Beefy.theme.dark;
|
||||
|
|
|
@ -13,7 +13,6 @@ using IDE.ui;
|
|||
using IDE.Util;
|
||||
using System.Threading;
|
||||
using System.Diagnostics;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
namespace IDE
|
||||
{
|
||||
|
@ -300,6 +299,9 @@ namespace IDE
|
|||
if (mIncludeKind != .Manual)
|
||||
return .None;
|
||||
|
||||
if (mParentFolder.mPath == null)
|
||||
return .SimpleSource;
|
||||
|
||||
var expectPath = scope String();
|
||||
expectPath.Append(mParentFolder.mPath);
|
||||
expectPath.Append(Path.DirectorySeparatorChar);
|
||||
|
@ -829,12 +831,13 @@ namespace IDE
|
|||
public enum TargetType
|
||||
{
|
||||
case BeefConsoleApplication,
|
||||
BeefWindowsApplication,
|
||||
BeefLib,
|
||||
CustomBuild,
|
||||
C_ConsoleApplication,
|
||||
C_WindowsApplication,
|
||||
BeefTest;
|
||||
BeefWindowsApplication,
|
||||
BeefLib,
|
||||
BeefDynLib,
|
||||
CustomBuild,
|
||||
C_ConsoleApplication,
|
||||
C_WindowsApplication,
|
||||
BeefTest;
|
||||
|
||||
public bool IsBeef
|
||||
{
|
||||
|
@ -843,9 +846,10 @@ namespace IDE
|
|||
switch (this)
|
||||
{
|
||||
case BeefConsoleApplication,
|
||||
BeefWindowsApplication,
|
||||
BeefLib,
|
||||
BeefTest: return true;
|
||||
BeefWindowsApplication,
|
||||
BeefLib,
|
||||
BeefDynLib,
|
||||
BeefTest: return true;
|
||||
default: return false;
|
||||
}
|
||||
}
|
||||
|
@ -1162,6 +1166,7 @@ namespace IDE
|
|||
//public String mLastImportDir = new String() ~ delete _;
|
||||
public bool mHasChanged;
|
||||
public bool mNeedsTargetRebuild;
|
||||
public bool mForceCustomCommands;
|
||||
public bool mEnabled = true;
|
||||
public bool mLocked;
|
||||
public bool mLockedDefault;
|
||||
|
|
|
@ -15,6 +15,8 @@ namespace IDE
|
|||
{
|
||||
class ScriptManager
|
||||
{
|
||||
public static ScriptManager sActiveManager;
|
||||
|
||||
class Target
|
||||
{
|
||||
public class Cmd
|
||||
|
@ -27,20 +29,29 @@ namespace IDE
|
|||
public Dictionary<String, Cmd> mCmds = new .() ~ DeleteDictionyAndKeysAndItems!(_);
|
||||
}
|
||||
|
||||
public enum CmdFlags
|
||||
{
|
||||
None,
|
||||
NoLines
|
||||
}
|
||||
|
||||
public class QueuedCmd
|
||||
{
|
||||
public String mCondition ~ delete _;
|
||||
|
||||
public CmdFlags mFlags;
|
||||
public bool mHandled = true;
|
||||
public String mCmd ~ delete _;
|
||||
public String mSrcFile ~ delete _;
|
||||
public int mLineNum = -1;
|
||||
|
||||
public int mIntParam;
|
||||
public int mExecIdx;
|
||||
public bool mNoWait;
|
||||
public Stopwatch mStopWatch ~ delete _;
|
||||
}
|
||||
|
||||
ScriptHelper mScriptHelper = new ScriptHelper() ~ delete _;
|
||||
ScriptHelper mScriptHelper = new ScriptHelper(this) ~ delete _;
|
||||
Target mRoot = new Target() ~ delete _;
|
||||
Dictionary<String, Variant> mVars = new .() ~
|
||||
{
|
||||
|
@ -52,13 +63,18 @@ namespace IDE
|
|||
delete _;
|
||||
};
|
||||
List<QueuedCmd> mCmdList = new .() ~ DeleteContainerAndItems!(_);
|
||||
bool mFailed;
|
||||
public bool mFailed;
|
||||
public bool mCancelled;
|
||||
public QueuedCmd mCurCmd;
|
||||
public Stopwatch mTimeoutStopwatch ~ delete _;
|
||||
public int mTimeoutMS;
|
||||
public String mExpectingError ~ delete _;
|
||||
public bool mHadExpectingError;
|
||||
public int mDoneTicks;
|
||||
public bool mAllowCompiling;
|
||||
public bool mSoftFail;
|
||||
public Verbosity mVerbosity = .Quiet;
|
||||
public String mProjectName ~ delete _;
|
||||
|
||||
public bool Failed
|
||||
{
|
||||
|
@ -146,9 +162,16 @@ namespace IDE
|
|||
var errStr = scope String(err);
|
||||
if (mCurCmd != null)
|
||||
{
|
||||
errStr.AppendF(" at line {0} in {1}\n\t{2}", mCurCmd.mLineNum + 1, mCurCmd.mSrcFile, mCurCmd.mCmd);
|
||||
if (mCurCmd.mFlags.HasFlag(.NoLines))
|
||||
errStr.AppendF(" in {}\n\t{}", mCurCmd.mSrcFile, mCurCmd.mCmd);
|
||||
else
|
||||
errStr.AppendF(" at line {} in {}\n\t{}", mCurCmd.mLineNum + 1, mCurCmd.mSrcFile, mCurCmd.mCmd);
|
||||
}
|
||||
gApp.Fail(errStr);
|
||||
|
||||
if (mSoftFail)
|
||||
gApp.OutputErrorLine(errStr);
|
||||
else
|
||||
gApp.Fail(errStr);
|
||||
|
||||
//TODO:
|
||||
//gApp.mRunningTestScript = false;
|
||||
|
@ -165,7 +188,7 @@ namespace IDE
|
|||
mFailed = false;
|
||||
}
|
||||
|
||||
public void QueueCommands(StreamReader streamReader, StringView filePath)
|
||||
public void QueueCommands(StreamReader streamReader, StringView filePath, CmdFlags flags)
|
||||
{
|
||||
int lineNum = 0;
|
||||
|
||||
|
@ -179,6 +202,7 @@ namespace IDE
|
|||
if ((!line.IsEmpty) && (!line.StartsWith("#")))
|
||||
{
|
||||
QueuedCmd queuedCmd = new .();
|
||||
queuedCmd.mFlags = flags;
|
||||
queuedCmd.mSrcFile = new String(filePath);
|
||||
queuedCmd.mLineNum = lineNum;
|
||||
|
||||
|
@ -223,6 +247,13 @@ namespace IDE
|
|||
}
|
||||
}
|
||||
|
||||
public void QueueCommands(StringView cmds, StringView filePath, CmdFlags flags)
|
||||
{
|
||||
StringStream strStream = scope .(cmds, .Reference);
|
||||
StreamReader reader = scope .(strStream);
|
||||
QueueCommands(reader, filePath, flags);
|
||||
}
|
||||
|
||||
public void QueueCommandFile(StringView filePath)
|
||||
{
|
||||
let streamReader = scope StreamReader();
|
||||
|
@ -232,7 +263,7 @@ namespace IDE
|
|||
return;
|
||||
}
|
||||
|
||||
QueueCommands(streamReader, filePath);
|
||||
QueueCommands(streamReader, filePath, .None);
|
||||
}
|
||||
|
||||
public void SetTimeoutMS(int timeoutMS)
|
||||
|
@ -245,14 +276,56 @@ namespace IDE
|
|||
mTimeoutMS = timeoutMS;
|
||||
}
|
||||
|
||||
public void Exec(StringView cmdLineView)
|
||||
public void Exec(StringView cmd)
|
||||
{
|
||||
var cmdLineView;
|
||||
cmdLineView.Trim();
|
||||
var cmd;
|
||||
cmd.Trim();
|
||||
|
||||
if ((cmdLineView.StartsWith("#")) || (cmdLineView.IsEmpty))
|
||||
if ((cmd.StartsWith("#")) || (cmd.IsEmpty))
|
||||
return;
|
||||
|
||||
if (cmd.StartsWith("%exec "))
|
||||
{
|
||||
mScriptHelper.ExecuteRaw(scope String(cmd, "%exec ".Length));
|
||||
return;
|
||||
}
|
||||
|
||||
if (cmd.StartsWith("%targetComplete "))
|
||||
{
|
||||
let projectName = cmd.Substring("%targetComplete ".Length);
|
||||
|
||||
if (gApp.mExecutionQueue.IsEmpty)
|
||||
return;
|
||||
|
||||
bool matched = false;
|
||||
if (var targetCompleteCmd = gApp.mExecutionQueue[0] as IDEApp.TargetCompletedCmd)
|
||||
{
|
||||
if (targetCompleteCmd.mProject.mProjectName == projectName)
|
||||
{
|
||||
targetCompleteCmd.mIsReady = true;
|
||||
matched = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (!matched)
|
||||
{
|
||||
mCurCmd.mHandled = false;
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
if (mCurCmd.mExecIdx == 0)
|
||||
{
|
||||
if (mVerbosity >= .Normal)
|
||||
{
|
||||
gApp.OutputLine("Executing Command: {}", cmd);
|
||||
if (mVerbosity >= .Detailed)
|
||||
{
|
||||
mCurCmd.mStopWatch = new .(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
StringView varName = .();
|
||||
|
||||
/*int eqPos = cmdLineView.IndexOf('=');
|
||||
|
@ -267,20 +340,20 @@ namespace IDE
|
|||
StringView methodName;
|
||||
List<Object> args = scope .();
|
||||
|
||||
int parenPos = cmdLineView.IndexOf('(');
|
||||
int parenPos = cmd.IndexOf('(');
|
||||
if (parenPos != -1)
|
||||
{
|
||||
methodName = cmdLineView.Substring(0, parenPos);
|
||||
methodName = cmd.Substring(0, parenPos);
|
||||
methodName.Trim();
|
||||
|
||||
int endParenPos = cmdLineView.LastIndexOf(')');
|
||||
int endParenPos = cmd.LastIndexOf(')');
|
||||
if (endParenPos == -1)
|
||||
{
|
||||
Fail("Missing argument end ')'");
|
||||
return;
|
||||
}
|
||||
|
||||
var postStr = StringView(cmdLineView, endParenPos + 1);
|
||||
var postStr = StringView(cmd, endParenPos + 1);
|
||||
postStr.Trim();
|
||||
if ((!postStr.IsEmpty) && (!postStr.StartsWith("#")))
|
||||
{
|
||||
|
@ -288,11 +361,15 @@ namespace IDE
|
|||
return;
|
||||
}
|
||||
|
||||
Workspace.Options workspaceOptions = null;
|
||||
Project project = null;
|
||||
Project.Options projectOptions = null;
|
||||
|
||||
bool inQuotes = false;
|
||||
int startIdx = parenPos;
|
||||
for (int idx = parenPos; idx <= endParenPos; idx++)
|
||||
{
|
||||
char8 c = cmdLineView[idx];
|
||||
char8 c = cmd[idx];
|
||||
if (c == '\\')
|
||||
{
|
||||
// Skip past slashed strings
|
||||
|
@ -305,7 +382,7 @@ namespace IDE
|
|||
}
|
||||
else if (((c == ',') || (c == ')')) && (!inQuotes))
|
||||
{
|
||||
StringView argView = cmdLineView.Substring(startIdx + 1, idx - startIdx - 1);
|
||||
StringView argView = cmd.Substring(startIdx + 1, idx - startIdx - 1);
|
||||
|
||||
argView.Trim();
|
||||
if (argView.IsEmpty)
|
||||
|
@ -319,9 +396,20 @@ namespace IDE
|
|||
|
||||
if (str.Contains('$'))
|
||||
{
|
||||
if (workspaceOptions == null)
|
||||
{
|
||||
workspaceOptions = gApp.GetCurWorkspaceOptions();
|
||||
if (mProjectName != null)
|
||||
{
|
||||
project = gApp.mWorkspace.FindProject(mProjectName);
|
||||
if (project != null)
|
||||
projectOptions = gApp.GetCurProjectOptions(project);
|
||||
}
|
||||
}
|
||||
|
||||
String newStr = scope:: .();
|
||||
String err = scope .();
|
||||
if (!gApp.DoResolveConfigString(null, null, null, str, err, newStr))
|
||||
if (!gApp.DoResolveConfigString(workspaceOptions, project, projectOptions, str, err, newStr))
|
||||
{
|
||||
Fail(scope String()..AppendF("Unknown macro string '{}' in '{}'", err, str));
|
||||
}
|
||||
|
@ -375,7 +463,7 @@ namespace IDE
|
|||
}
|
||||
else
|
||||
{
|
||||
methodName = cmdLineView;
|
||||
methodName = cmd;
|
||||
}
|
||||
|
||||
Target curTarget = mRoot;
|
||||
|
@ -539,6 +627,12 @@ namespace IDE
|
|||
return false;
|
||||
}
|
||||
|
||||
public void Cancel()
|
||||
{
|
||||
mCancelled = true;
|
||||
ClearAndDeleteItems(mCmdList);
|
||||
}
|
||||
|
||||
public void Update()
|
||||
{
|
||||
if (mFailed)
|
||||
|
@ -547,9 +641,10 @@ namespace IDE
|
|||
if ((mTimeoutMS > 0) && (gApp.mRunningTestScript))
|
||||
{
|
||||
if (mTimeoutStopwatch.ElapsedMilliseconds >= mTimeoutMS)
|
||||
Fail("Script has timed out: {0}ms", mTimeoutStopwatch.ElapsedMilliseconds);
|
||||
Fail("Script has timed out: {:0.00}s", mTimeoutStopwatch.ElapsedMilliseconds / 1000.0f);
|
||||
}
|
||||
|
||||
ScriptManager.sActiveManager = this;
|
||||
while ((!mCmdList.IsEmpty) && (!mFailed))
|
||||
{
|
||||
mCurCmd = mCmdList[0];
|
||||
|
@ -568,7 +663,10 @@ namespace IDE
|
|||
if (mCurCmd.mCondition != null)
|
||||
doExec = CheckCondition(mCurCmd.mCondition);
|
||||
if (doExec)
|
||||
{
|
||||
Exec(mCurCmd.mCmd);
|
||||
mCurCmd.mExecIdx++;
|
||||
}
|
||||
|
||||
if (mCmdList.IsEmpty)
|
||||
break;
|
||||
|
@ -576,16 +674,30 @@ namespace IDE
|
|||
if (!mCurCmd.mHandled)
|
||||
break; // Try again next update
|
||||
|
||||
if (mCurCmd.mStopWatch != null)
|
||||
{
|
||||
mCurCmd.mStopWatch.Stop();
|
||||
if (mCurCmd.mStopWatch.ElapsedMilliseconds > 10)
|
||||
gApp.OutputLine("Command Time: {:0.00}s", mCurCmd.mStopWatch.ElapsedMilliseconds / 1000.0f);
|
||||
}
|
||||
|
||||
mCmdList.RemoveAt(0);
|
||||
delete mCurCmd;
|
||||
mCurCmd = null;
|
||||
}
|
||||
ScriptManager.sActiveManager = null;
|
||||
}
|
||||
}
|
||||
|
||||
class ScriptHelper
|
||||
{
|
||||
public EditWidgetContent.LineAndColumn mMarkedPos;
|
||||
public ScriptManager mScriptManager;
|
||||
|
||||
public this(ScriptManager scriptManager)
|
||||
{
|
||||
mScriptManager = scriptManager;
|
||||
}
|
||||
|
||||
void FixFilePath(String filePath, ProjectFolder folder)
|
||||
{
|
||||
|
@ -632,7 +744,7 @@ namespace IDE
|
|||
|
||||
if (!File.Exists(outFilePath))
|
||||
{
|
||||
gApp.mScriptManager.Fail("Unable to locate project file '{0}'", outFilePath);
|
||||
ScriptManager.sActiveManager.Fail("Unable to locate project file '{0}'", outFilePath);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -647,7 +759,7 @@ namespace IDE
|
|||
|
||||
if (!File.Exists(outFilePath))
|
||||
{
|
||||
gApp.mScriptManager.Fail("Unable to locate file '{0}'", outFilePath);
|
||||
ScriptManager.sActiveManager.Fail("Unable to locate file '{0}'", outFilePath);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -656,7 +768,7 @@ namespace IDE
|
|||
var sourceViewPanel = gApp.GetActiveSourceViewPanel();
|
||||
if (sourceViewPanel == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("No active source view panel");
|
||||
ScriptManager.sActiveManager.Fail("No active source view panel");
|
||||
return null;
|
||||
}
|
||||
sourceViewPanel.EnsureReady();
|
||||
|
@ -667,13 +779,13 @@ namespace IDE
|
|||
{
|
||||
var textPanel = gApp.GetActivePanel() as TextPanel;
|
||||
if (textPanel == null)
|
||||
gApp.mScriptManager.Fail("No active text panel");
|
||||
ScriptManager.sActiveManager.Fail("No active text panel");
|
||||
return textPanel;
|
||||
}
|
||||
|
||||
public bool Evaluate(String evalStr, String outVal, DebugManager.EvalExpressionFlags expressionFlags = .AllowCalls | .AllowSideEffects)
|
||||
{
|
||||
var curCmd = gApp.mScriptManager.mCurCmd;
|
||||
var curCmd = ScriptManager.sActiveManager.mCurCmd;
|
||||
|
||||
if (curCmd.mIntParam == 1) // Pending
|
||||
{
|
||||
|
@ -741,7 +853,7 @@ namespace IDE
|
|||
{
|
||||
int wantTicks = length * gApp.RefreshRate / 1000;
|
||||
|
||||
var curCmd = gApp.mScriptManager.mCurCmd;
|
||||
var curCmd = ScriptManager.sActiveManager.mCurCmd;
|
||||
if ((++curCmd.mIntParam <= wantTicks) || (length < 0)) // Negative is forever
|
||||
curCmd.mHandled = false;
|
||||
}
|
||||
|
@ -750,7 +862,7 @@ namespace IDE
|
|||
public void SleepTicks(int length)
|
||||
{
|
||||
int wantTicks = length;
|
||||
var curCmd = gApp.mScriptManager.mCurCmd;
|
||||
var curCmd = ScriptManager.sActiveManager.mCurCmd;
|
||||
if ((++curCmd.mIntParam <= wantTicks) || (length < 0)) // Negative is forever
|
||||
curCmd.mHandled = false;
|
||||
}
|
||||
|
@ -780,12 +892,25 @@ namespace IDE
|
|||
return false;
|
||||
if (gApp.[Friend]mDeferredOpen != .None)
|
||||
return false;
|
||||
if (gApp.mWantsRehupCallstack)
|
||||
return false;
|
||||
|
||||
if ((gApp.mExecutionPaused) && (gApp.mDebugger.IsPaused()))
|
||||
{
|
||||
if (gApp.mWantsRehupCallstack)
|
||||
return false;
|
||||
}
|
||||
if (gApp.mWantsClean || gApp.mWantsBeefClean)
|
||||
return false;
|
||||
|
||||
if ((!gApp.IsCompiling) && (!gApp.AreTestsRunning()) && (!gApp.mDebugger.HasPendingDebugLoads()) &&
|
||||
if (gApp.IsCompiling)
|
||||
{
|
||||
if (!ScriptManager.sActiveManager.mAllowCompiling)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!gApp.[Friend]mExecutionInstances.IsEmpty)
|
||||
return false;
|
||||
|
||||
if ((!gApp.AreTestsRunning()) && (!gApp.mDebugger.HasPendingDebugLoads()) &&
|
||||
((gApp.mExecutionPaused) || (!gApp.mDebugger.mIsRunning)))
|
||||
{
|
||||
var runState = gApp.mDebugger.GetRunState();
|
||||
|
@ -830,14 +955,14 @@ namespace IDE
|
|||
[IDECommand]
|
||||
public void WaitForPaused()
|
||||
{
|
||||
var curCmd = gApp.mScriptManager.mCurCmd;
|
||||
var curCmd = ScriptManager.sActiveManager.mCurCmd;
|
||||
curCmd.mHandled = IsPaused();
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
public void WaitForResolve()
|
||||
{
|
||||
var curCmd = gApp.mScriptManager.mCurCmd;
|
||||
var curCmd = ScriptManager.sActiveManager.mCurCmd;
|
||||
curCmd.mHandled = IsPaused() && (!gApp.mBfResolveCompiler.IsPerformingBackgroundOperation());
|
||||
}
|
||||
|
||||
|
@ -857,7 +982,7 @@ namespace IDE
|
|||
case .Ok(let flags):
|
||||
gApp.mDebugger.SetSymSrvOptions(symCacheDir, symSrvStr, flags);
|
||||
case .Err:
|
||||
gApp.mScriptManager.Fail("Failed to parse flags");
|
||||
ScriptManager.sActiveManager.Fail("Failed to parse flags");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -875,7 +1000,7 @@ namespace IDE
|
|||
{
|
||||
if (Utils.DelTree(dirPath) case .Err)
|
||||
{
|
||||
gApp.mScriptManager.Fail(scope String()..AppendF("Failed to deltree '{}'", dirPath));
|
||||
ScriptManager.sActiveManager.Fail(scope String()..AppendF("Failed to deltree '{}'", dirPath));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -885,7 +1010,7 @@ namespace IDE
|
|||
let fileStream = scope FileStream();
|
||||
if (fileStream.Create(path) case .Err)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Failed to create file '{}'", path);
|
||||
ScriptManager.sActiveManager.Fail("Failed to create file '{}'", path);
|
||||
return;
|
||||
}
|
||||
fileStream.Write(text);
|
||||
|
@ -896,7 +1021,7 @@ namespace IDE
|
|||
{
|
||||
if (File.Move(origPath, newPath) case .Err)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Failed to move file '{}' to '{}'", origPath, newPath);
|
||||
ScriptManager.sActiveManager.Fail("Failed to move file '{}' to '{}'", origPath, newPath);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -905,10 +1030,147 @@ namespace IDE
|
|||
{
|
||||
if (File.Delete(path) case .Err)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Failed to delete file '{}'", path);
|
||||
mScriptManager.Fail("Failed to delete file '{}'", path);
|
||||
}
|
||||
}
|
||||
|
||||
/*[IDECommand]
|
||||
public void Copy(String srcPath, String destPath)
|
||||
{
|
||||
|
||||
}*/
|
||||
|
||||
[IDECommand]
|
||||
public void CopyFilesIfNewer(String srcPath, String destPath)
|
||||
{
|
||||
int copyCount = 0;
|
||||
int foundCount = 0;
|
||||
|
||||
void Do(String srcPath, String destPath)
|
||||
{
|
||||
bool checkedDestDir = false;
|
||||
|
||||
for (var entry in Directory.Enumerate(srcPath, .Directories | .Files))
|
||||
{
|
||||
foundCount++;
|
||||
|
||||
if (mScriptManager.mFailed)
|
||||
return;
|
||||
|
||||
String srcFilePath = scope .();
|
||||
entry.GetFilePath(srcFilePath);
|
||||
|
||||
String srcFileName = scope .();
|
||||
entry.GetFileName(srcFileName);
|
||||
|
||||
String destFilePath = scope .();
|
||||
Path.GetAbsolutePath(srcFileName, destPath, destFilePath);
|
||||
|
||||
if (entry.IsDirectory)
|
||||
{
|
||||
Do(srcFilePath, destFilePath);
|
||||
continue;
|
||||
}
|
||||
|
||||
DateTime srcDate;
|
||||
if (!(File.GetLastWriteTime(srcFilePath) case .Ok(out srcDate)))
|
||||
continue;
|
||||
|
||||
bool wantCopy = true;
|
||||
if (File.GetLastWriteTime(destFilePath) case .Ok(let destDate))
|
||||
{
|
||||
wantCopy = srcDate > destDate;
|
||||
}
|
||||
|
||||
if (!wantCopy)
|
||||
continue;
|
||||
|
||||
if (!checkedDestDir)
|
||||
{
|
||||
if (Directory.CreateDirectory(destPath) case .Err)
|
||||
{
|
||||
mScriptManager.Fail("Failed to create directory '{}'", destPath);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (File.Copy(srcFilePath, destFilePath) case .Err)
|
||||
{
|
||||
mScriptManager.Fail("Failed to copy '{}' to '{}'", srcFilePath, destFilePath);
|
||||
return;
|
||||
}
|
||||
|
||||
copyCount++;
|
||||
}
|
||||
}
|
||||
|
||||
Do(srcPath, destPath);
|
||||
|
||||
if (foundCount == 0)
|
||||
{
|
||||
String srcDirPath = scope .();
|
||||
Path.GetDirectoryPath(srcPath, srcDirPath);
|
||||
if (!Directory.Exists(srcDirPath))
|
||||
{
|
||||
mScriptManager.Fail("Source directory does not exist: {}", srcDirPath);
|
||||
}
|
||||
else if ((!srcDirPath.Contains('*')) && (!srcDirPath.Contains('?')) && (!File.Exists(srcDirPath)))
|
||||
{
|
||||
mScriptManager.Fail("Source file does not exist: {}", srcPath);
|
||||
}
|
||||
}
|
||||
|
||||
if ((!mScriptManager.mFailed) && (copyCount > 0) && (mScriptManager.mVerbosity >= .Normal))
|
||||
{
|
||||
if (mScriptManager.mCurCmd.mStopWatch != null)
|
||||
{
|
||||
mScriptManager.mCurCmd.mStopWatch.Stop();
|
||||
gApp.OutputLine("{} files copied from '{}' to '{}' in {:0.00}s", foundCount, srcPath, destPath, mScriptManager.mCurCmd.mStopWatch.ElapsedMilliseconds / 1000.0f);
|
||||
DeleteAndNullify!(mScriptManager.mCurCmd.mStopWatch);
|
||||
}
|
||||
else
|
||||
gApp.OutputLine("{} files copied from '{}' to '{}'", foundCount, srcPath, destPath);
|
||||
}
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
public void ExecuteRaw(String cmd)
|
||||
{
|
||||
var exePath = scope String();
|
||||
int spacePos;
|
||||
if (cmd.StartsWith("\""))
|
||||
{
|
||||
spacePos = cmd.IndexOf('"', 1) + 1;
|
||||
if (spacePos != -1)
|
||||
exePath.Append(cmd, 1, spacePos - 2);
|
||||
}
|
||||
else
|
||||
{
|
||||
spacePos = cmd.IndexOf(' ');
|
||||
if (spacePos != -1)
|
||||
exePath.Append(cmd, 0, spacePos);
|
||||
}
|
||||
|
||||
if ((spacePos == -1) && (!cmd.IsEmpty))
|
||||
{
|
||||
mScriptManager.Fail("Invalid command '{0}' in '{1}'", cmd, mScriptManager.mCurCmd.mSrcFile);
|
||||
return;
|
||||
}
|
||||
|
||||
if (spacePos > 0)
|
||||
{
|
||||
var exeArgs = scope String();
|
||||
exeArgs.Append(cmd, spacePos + 1);
|
||||
gApp.DoRun(exePath, exeArgs, gApp.mInstallDir, .None);
|
||||
}
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
public void Execute(String path)
|
||||
{
|
||||
ExecuteRaw(path);
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
public void SetFileWatcherDelay(int32 delay)
|
||||
{
|
||||
|
@ -921,7 +1183,7 @@ namespace IDE
|
|||
String content = scope .();
|
||||
if (File.ReadAllText(origPath, content, true) case .Err)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Failed to open file '{}'", origPath);
|
||||
ScriptManager.sActiveManager.Fail("Failed to open file '{}'", origPath);
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -942,7 +1204,7 @@ namespace IDE
|
|||
FileStream tempStream = scope .();
|
||||
if (tempStream.Create(tempPath) case .Err)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Failed to create temp file '{}'", tempPath);
|
||||
ScriptManager.sActiveManager.Fail("Failed to create temp file '{}'", tempPath);
|
||||
return;
|
||||
}
|
||||
tempStream.Write(content);
|
||||
|
@ -950,13 +1212,13 @@ namespace IDE
|
|||
|
||||
if (File.Move(tempPath, newPath) case .Err)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Failed to move file '{}' to '{}'", origPath, newPath);
|
||||
ScriptManager.sActiveManager.Fail("Failed to move file '{}' to '{}'", origPath, newPath);
|
||||
return;
|
||||
}
|
||||
|
||||
if (File.Delete(origPath) case .Err)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Failed to delete file '{}'", origPath);
|
||||
ScriptManager.sActiveManager.Fail("Failed to delete file '{}'", origPath);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -982,7 +1244,7 @@ namespace IDE
|
|||
var panelHeader = sourceViewPanel.[Friend]mPanelHeader;
|
||||
if (panelHeader == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("No panel present");
|
||||
ScriptManager.sActiveManager.Fail("No panel present");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -998,7 +1260,7 @@ namespace IDE
|
|||
}
|
||||
}
|
||||
|
||||
gApp.mScriptManager.Fail("Button '{0}' not found", buttonName);
|
||||
ScriptManager.sActiveManager.Fail("Button '{0}' not found", buttonName);
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
|
@ -1020,7 +1282,7 @@ namespace IDE
|
|||
|
||||
if (outVal != evalResult)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Assert failed: {0} == {1}", outVal, evalResult);
|
||||
ScriptManager.sActiveManager.Fail("Assert failed: {0} == {1}", outVal, evalResult);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1033,7 +1295,7 @@ namespace IDE
|
|||
|
||||
if (!outVal.Contains(evalResult))
|
||||
{
|
||||
gApp.mScriptManager.Fail("Assert failed: {0} contains {1}", outVal, evalResult);
|
||||
ScriptManager.sActiveManager.Fail("Assert failed: {0} contains {1}", outVal, evalResult);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1056,7 +1318,7 @@ namespace IDE
|
|||
gApp.mDebugger.UpdateCallStack();
|
||||
if (stackCount == gApp.mDebugger.GetCallStackCount())
|
||||
{
|
||||
gApp.mScriptManager.Fail("Stack idx '{0}' is out of range", selectIdx);
|
||||
ScriptManager.sActiveManager.Fail("Stack idx '{0}' is out of range", selectIdx);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1088,7 +1350,7 @@ namespace IDE
|
|||
stackIdx++;
|
||||
}
|
||||
|
||||
gApp.mScriptManager.Fail("Failed to find stack frame containing string '{}'", str);
|
||||
ScriptManager.sActiveManager.Fail("Failed to find stack frame containing string '{}'", str);
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
|
@ -1124,7 +1386,7 @@ namespace IDE
|
|||
|
||||
if (methodName != stackframeInfo)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Expect method name '{0}', got '{1}'", methodName, stackframeInfo);
|
||||
ScriptManager.sActiveManager.Fail("Expect method name '{0}', got '{1}'", methodName, stackframeInfo);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1162,7 +1424,7 @@ namespace IDE
|
|||
var lastBreakpoint = gApp.mDebugger.mBreakpointList.Back;
|
||||
if (lastBreakpoint == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("No last breakpoint");
|
||||
ScriptManager.sActiveManager.Fail("No last breakpoint");
|
||||
return;
|
||||
}
|
||||
lastBreakpoint.SetCondition(condition);
|
||||
|
@ -1174,13 +1436,13 @@ namespace IDE
|
|||
var lastBreakpoint = gApp.mDebugger.mBreakpointList.Back;
|
||||
if (lastBreakpoint == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("No last breakpoint");
|
||||
ScriptManager.sActiveManager.Fail("No last breakpoint");
|
||||
return;
|
||||
}
|
||||
switch (Enum.Parse<Breakpoint.HitCountBreakKind>(hitCountBreakKindStr))
|
||||
{
|
||||
case .Err:
|
||||
gApp.mScriptManager.Fail("Invalid break kind: '{0}'", hitCountBreakKindStr);
|
||||
ScriptManager.sActiveManager.Fail("Invalid break kind: '{0}'", hitCountBreakKindStr);
|
||||
case .Ok(let hitCountBreakKind):
|
||||
lastBreakpoint.SetHitCountTarget(hitCountTarget, hitCountBreakKind);
|
||||
}
|
||||
|
@ -1202,20 +1464,20 @@ namespace IDE
|
|||
var textPanel = GetActiveTextPanel();
|
||||
if (textPanel == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("No text panel active");
|
||||
ScriptManager.sActiveManager.Fail("No text panel active");
|
||||
return null;
|
||||
}
|
||||
|
||||
var ewc = textPanel.EditWidget.mEditWidgetContent as SourceEditWidgetContent;
|
||||
if (ewc == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Not an autocomplete text view");
|
||||
ScriptManager.sActiveManager.Fail("Not an autocomplete text view");
|
||||
return null;
|
||||
}
|
||||
|
||||
if (ewc.mAutoComplete == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("No autocomplete content");
|
||||
ScriptManager.sActiveManager.Fail("No autocomplete content");
|
||||
return null;
|
||||
}
|
||||
|
||||
|
@ -1252,9 +1514,9 @@ namespace IDE
|
|||
if (found != wantsFind)
|
||||
{
|
||||
if (wantsFind)
|
||||
gApp.mScriptManager.Fail("Autocomplete entry '{0}' not found", wantEntry);
|
||||
ScriptManager.sActiveManager.Fail("Autocomplete entry '{0}' not found", wantEntry);
|
||||
else
|
||||
gApp.mScriptManager.Fail("Autocomplete entry '{0}' found, but it shouldn't have been", wantEntry);
|
||||
ScriptManager.sActiveManager.Fail("Autocomplete entry '{0}' found, but it shouldn't have been", wantEntry);
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
@ -1304,7 +1566,7 @@ namespace IDE
|
|||
|
||||
if (contents != wantsContents)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Autocomplete not showing expected values. Expected '{}', got '{}'.", wantsContents, contents);
|
||||
ScriptManager.sActiveManager.Fail("Autocomplete not showing expected values. Expected '{}', got '{}'.", wantsContents, contents);
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
@ -1337,14 +1599,14 @@ namespace IDE
|
|||
|
||||
if (!Path.Equals(filePath, sourceViewPanel.mFilePath))
|
||||
{
|
||||
gApp.mScriptManager.Fail("Expected source file '{0}', got '{1}'", filePath, sourceViewPanel.mFilePath);
|
||||
ScriptManager.sActiveManager.Fail("Expected source file '{0}', got '{1}'", filePath, sourceViewPanel.mFilePath);
|
||||
return;
|
||||
}
|
||||
|
||||
let atLine = sourceViewPanel.mEditWidget.mEditWidgetContent.CursorLineAndColumn.mLine + 1;
|
||||
if (atLine != lineNum)
|
||||
{
|
||||
gApp.mScriptManager.Fail("Expected line '{0}', got '{1}'", lineNum, atLine);
|
||||
ScriptManager.sActiveManager.Fail("Expected line '{0}', got '{1}'", lineNum, atLine);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -1357,7 +1619,7 @@ namespace IDE
|
|||
var textPanel = GetActiveTextPanel();
|
||||
if (textPanel == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("No active text panel");
|
||||
ScriptManager.sActiveManager.Fail("No active text panel");
|
||||
return;
|
||||
}
|
||||
var ewc = textPanel.EditWidget.mEditWidgetContent;
|
||||
|
@ -1387,7 +1649,7 @@ namespace IDE
|
|||
}
|
||||
}
|
||||
|
||||
gApp.mScriptManager.Fail("Unable to find text '{0}'", findText);
|
||||
ScriptManager.sActiveManager.Fail("Unable to find text '{0}'", findText);
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
|
@ -1411,7 +1673,7 @@ namespace IDE
|
|||
|
||||
if (!lineText.Contains(findText))
|
||||
{
|
||||
gApp.mScriptManager.Fail("Lines does not contain text '{0}'", findText);
|
||||
ScriptManager.sActiveManager.Fail("Lines does not contain text '{0}'", findText);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1514,12 +1776,12 @@ namespace IDE
|
|||
{
|
||||
if (gApp.IsCompiling)
|
||||
{
|
||||
gApp.mScriptManager.mCurCmd.mHandled = false;
|
||||
ScriptManager.sActiveManager.mCurCmd.mHandled = false;
|
||||
return;
|
||||
}
|
||||
|
||||
if (gApp.mLastCompileFailed)
|
||||
gApp.mScriptManager.Fail("Compile failed");
|
||||
ScriptManager.sActiveManager.Fail("Compile failed");
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
|
@ -1532,7 +1794,7 @@ namespace IDE
|
|||
var ewc = sourceViewPanel.mEditWidget.mEditWidgetContent;
|
||||
GotoText(textFrom);
|
||||
|
||||
if (gApp.mScriptManager.Failed)
|
||||
if (ScriptManager.sActiveManager.Failed)
|
||||
return;
|
||||
|
||||
|
||||
|
@ -1630,18 +1892,18 @@ namespace IDE
|
|||
[IDECommand]
|
||||
public void SetExpectError(String error)
|
||||
{
|
||||
DeleteAndNullify!(gApp.mScriptManager.mExpectingError);
|
||||
gApp.mScriptManager.mExpectingError = new String(error);
|
||||
gApp.mScriptManager.mHadExpectingError = true;
|
||||
DeleteAndNullify!(ScriptManager.sActiveManager.mExpectingError);
|
||||
ScriptManager.sActiveManager.mExpectingError = new String(error);
|
||||
ScriptManager.sActiveManager.mHadExpectingError = true;
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
public void ExpectError()
|
||||
{
|
||||
if (gApp.mScriptManager.mExpectingError != null)
|
||||
if (ScriptManager.sActiveManager.mExpectingError != null)
|
||||
{
|
||||
DeleteAndNullify!(gApp.mScriptManager.mExpectingError);
|
||||
gApp.mScriptManager.Fail("Expected error did not occur");
|
||||
DeleteAndNullify!(ScriptManager.sActiveManager.mExpectingError);
|
||||
ScriptManager.sActiveManager.Fail("Expected error did not occur");
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1651,7 +1913,7 @@ namespace IDE
|
|||
var textPanel = GetActiveSourceViewPanel();
|
||||
if (textPanel == null)
|
||||
{
|
||||
gApp.mScriptManager.Fail("No active text panel");
|
||||
ScriptManager.sActiveManager.Fail("No active text panel");
|
||||
return;
|
||||
}
|
||||
var ewc = textPanel.EditWidget.mEditWidgetContent;
|
||||
|
@ -1675,9 +1937,9 @@ namespace IDE
|
|||
if (hasError != expectedError)
|
||||
{
|
||||
if (hasError)
|
||||
gApp.mScriptManager.Fail("Unexpected error at line {0} in {1}\n\t", lineIdx + 1, textPanel.mFilePath);
|
||||
ScriptManager.sActiveManager.Fail("Unexpected error at line {0} in {1}\n\t", lineIdx + 1, textPanel.mFilePath);
|
||||
else
|
||||
gApp.mScriptManager.Fail("Expected error at line {0} in {1} but didn't encounter one\n\t", lineIdx + 1, textPanel.mFilePath);
|
||||
ScriptManager.sActiveManager.Fail("Expected error at line {0} in {1} but didn't encounter one\n\t", lineIdx + 1, textPanel.mFilePath);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -1686,7 +1948,7 @@ namespace IDE
|
|||
[IDECommand]
|
||||
public void Stop()
|
||||
{
|
||||
gApp.mScriptManager.Clear();
|
||||
ScriptManager.sActiveManager.Clear();
|
||||
}
|
||||
|
||||
[IDECommand]
|
||||
|
|
|
@ -1,7 +1,6 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Threading;
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
|
|
|
@ -2,7 +2,6 @@ using System;
|
|||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Text;
|
||||
using System.Threading;
|
||||
using System.Threading.Tasks;
|
||||
|
|
|
@ -632,7 +632,7 @@ namespace IDE
|
|||
mProjectNameMap.Clear();
|
||||
}
|
||||
|
||||
public Project FindProject(String projectName)
|
||||
public Project FindProject(StringView projectName)
|
||||
{
|
||||
if (mProjectNameMap.IsEmpty)
|
||||
{
|
||||
|
@ -654,7 +654,12 @@ namespace IDE
|
|||
Add(alias, project);
|
||||
}
|
||||
}
|
||||
return mProjectNameMap.GetValueOrDefault(projectName);
|
||||
|
||||
if (mProjectNameMap.TryGetWith(projectName, var matchKey, var value))
|
||||
{
|
||||
return value;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public void SetupDefault(Options options, String configName, String platformName)
|
||||
|
|
|
@ -337,10 +337,8 @@ namespace IDE.ui
|
|||
mUsedHistory = false;
|
||||
if (cmdText.StartsWith("%"))
|
||||
{
|
||||
StringStream strStream = scope .(StringView(cmdText, 1), .Reference);
|
||||
StreamReader reader = scope .(strStream);
|
||||
gApp.mScriptManager.Clear();
|
||||
gApp.mScriptManager.QueueCommands(reader, "Immediate");
|
||||
gApp.mScriptManager.QueueCommands(StringView(cmdText, 1), "Immediate", .NoLines);
|
||||
}
|
||||
else
|
||||
result = mResultHoverWatch.Eval(cmdText, false);
|
||||
|
|
|
@ -15,10 +15,11 @@ namespace IDE.ui
|
|||
public PathEditWidget mDirectoryEdit;
|
||||
public EditWidget mNameEdit;
|
||||
public DarkComboBox mTargetComboBox;
|
||||
static String[4] sApplicationTypeNames =
|
||||
static String[5] sApplicationTypeNames =
|
||||
.("Console Application",
|
||||
"Windows Application",
|
||||
"Library",
|
||||
"Dynamic Library",
|
||||
"Custom Build");
|
||||
public bool mDirChanged;
|
||||
public String mDirBase ~ delete _;
|
||||
|
|
|
@ -593,6 +593,7 @@ namespace IDE.ui
|
|||
"Console Application",
|
||||
"Windows Application",
|
||||
"Library",
|
||||
"Dynamic Library",
|
||||
"Custom Build"
|
||||
});
|
||||
AddPropertiesItem(root, "Project Name Aliases", "mAliases");
|
||||
|
|
|
@ -4,7 +4,6 @@ using System.Text;
|
|||
using System.Threading.Tasks;
|
||||
using System.Threading;
|
||||
using System.Diagnostics;
|
||||
using System.Runtime.InteropServices;
|
||||
using Beefy;
|
||||
using Beefy.widgets;
|
||||
using Beefy.theme;
|
||||
|
|
|
@ -5,7 +5,6 @@ using System.Threading.Tasks;
|
|||
using System.Threading;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
using System.Runtime.InteropServices;
|
||||
using Beefy;
|
||||
using Beefy.widgets;
|
||||
using Beefy.theme;
|
||||
|
|
|
@ -351,6 +351,10 @@ namespace IDE.ui
|
|||
{
|
||||
DrawStatusBox("Running Script");
|
||||
}
|
||||
else if ((gApp.mBuildContext != null) && (!completionPct.HasValue))
|
||||
{
|
||||
DrawStatusBox("Custom Build Commands...");
|
||||
}
|
||||
else
|
||||
mStatusBoxUpdateCnt = -1;
|
||||
|
||||
|
|
|
@ -974,7 +974,7 @@ namespace IDE.Util
|
|||
bit_buf |= (((tinfl_bit_buf_t)pIn_buf_cur[0]) << num_bits) | (((tinfl_bit_buf_t)pIn_buf_cur[1]) << (num_bits + 8)); pIn_buf_cur += 2; num_bits += 16;
|
||||
}
|
||||
}
|
||||
if ((temp = (uint16)pHuff.m_look_up[bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)]) >= 0)
|
||||
if ((temp = pHuff.m_look_up[bit_buf & (TINFL_FAST_LOOKUP_SIZE - 1)]) >= 0)
|
||||
{
|
||||
code_len = temp >> 9;
|
||||
temp &= 511;
|
||||
|
@ -984,7 +984,7 @@ namespace IDE.Util
|
|||
code_len = TINFL_FAST_LOOKUP_BITS;
|
||||
repeat
|
||||
{
|
||||
temp = (uint16)pHuff.m_tree[~temp + (int32)((bit_buf >> code_len++) & 1)];
|
||||
temp = pHuff.m_tree[~temp + (int32)((bit_buf >> code_len++) & 1)];
|
||||
}
|
||||
while (temp < 0);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue