Small change in Output behaviour.
This commit is contained in:
parent
8e5475f59b
commit
01d6cd1243
3 changed files with 8 additions and 3 deletions
|
@ -204,6 +204,9 @@ namespace SuperVM.Assembler
|
|||
foreach (var patch in patches)
|
||||
{
|
||||
var target = patch.Value;
|
||||
if (labels.ContainsKey(target) == false)
|
||||
throw new InvalidOperationException($"Missing label: {target}");
|
||||
|
||||
var position = labels[target];
|
||||
code[patch.Key] =
|
||||
(code[patch.Key] & 0xFFFFFFFF) |
|
||||
|
|
|
@ -6,7 +6,8 @@
|
|||
xmlns:local="clr-namespace:SuperVM.VisualDebugger"
|
||||
xmlns:avalon="clr-namespace:ICSharpCode.AvalonEdit;assembly=ICSharpCode.AvalonEdit"
|
||||
mc:Ignorable="d"
|
||||
Title="MainWindow" Height="350" Width="525">
|
||||
WindowStartupLocation="CenterScreen"
|
||||
Title="MainWindow" Height="768" Width="1024">
|
||||
<Window.DataContext>
|
||||
<local:VirtualMachineModel />
|
||||
</Window.DataContext>
|
||||
|
@ -125,7 +126,7 @@
|
|||
AcceptsReturn="True"
|
||||
FontFamily="Consolas"
|
||||
VerticalContentAlignment="Top"
|
||||
Text="{Binding Path=Output}"/>
|
||||
Text="{Binding Path=Output, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"/>
|
||||
</TabItem>
|
||||
<TabItem Header="Memory" Grid.IsSharedSizeScope="True">
|
||||
<DockPanel>
|
||||
|
@ -164,6 +165,7 @@
|
|||
FontFamily="Consolas"
|
||||
Background="#222"
|
||||
Foreground="#DDD"
|
||||
FontSize="16"
|
||||
Code="{Binding Path=Source, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}" />
|
||||
</TabItem>
|
||||
<TabItem Header="Code">
|
||||
|
|
|
@ -172,7 +172,7 @@ namespace SuperVM.VisualDebugger
|
|||
}
|
||||
|
||||
public StackItem[] Stack => Enumerable
|
||||
.Range(0, (int)this.process.StackPointer)
|
||||
.Range(1, (int)this.process.StackPointer)
|
||||
.Select(i => new StackItem(i, this.process))
|
||||
.ToArray();
|
||||
|
||||
|
|
Loading…
Reference in a new issue