public virtual string FormatOperand(X86Operand operand)
{
if (operand == null)
return string.Empty;
string prefix = FormatOperandUsagePrefix(operand.OperandUsage);
var formattedValue = FormatValue(operand.Value);
var formattedOffset = FormatOffset(operand.Offset);
var formattedScaledIndex = operand.ScaledIndex != null ? '+' + operand.ScaledIndex.ToString() : string.Empty;
return prefix == null
? formattedValue
: string.Format("{0} [{1}{2}{3}]", prefix, formattedValue, formattedScaledIndex, formattedOffset);
}