/// <summary> /// Formats the location according to script preferences /// </summary> /// <param name="script">The script.</param> public string FormatLocation(Script script) { if (IsClrLocation) { return("[clr]"); } if (FromLine == ToLine) { if (FromChar == ToChar) { return($"(Line {FromLine.ToString()}, Position {FromChar.ToString()})"); } return($"(Line {FromLine.ToString()}, Position {FromChar.ToString()}-{ToChar.ToString()})"); } return($"(Line {FromLine.ToString()}, Position {FromChar.ToString()}-{ToLine.ToString()},{ToChar.ToString()})"); }
/// <summary> /// Returns a <see cref="System.String" /> that represents this instance. /// </summary> /// <returns> /// A <see cref="System.String" /> that represents this instance. /// </returns> public override string ToString() { return($"{(IsStepStop ? "*" : " ")} ({FromLine.ToString()}, {FromChar.ToString()}) -> ({ToLine.ToString()}, {ToChar.ToString()})"); }