mirror of
https://github.com/danbulant/Cosmos
synced 2026-05-20 21:08:51 +00:00
28 lines
758 B
C#
28 lines
758 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
|
|
namespace Indy.IL2CPU.Assembler.X86 {
|
|
[OpCode(0xFFFFFFFF, "mov")]
|
|
public class Move: Instruction {
|
|
public readonly string Destination;
|
|
public readonly string Source;
|
|
public readonly string Size;
|
|
public Move(string aSize, string aDestination, string aSource):this(aDestination, aSource) {
|
|
Size = aSize;
|
|
}
|
|
public Move(string aDestination, string aSource) {
|
|
Destination = aDestination;
|
|
Source = aSource;
|
|
}
|
|
|
|
public override string ToString() {
|
|
if (String.IsNullOrEmpty(Size)) {
|
|
return "mov " + Destination + "," + Source;
|
|
} else {
|
|
return "mov " + Size + " " + Destination + ", " + Source;
|
|
}
|
|
}
|
|
}
|
|
}
|