xFunc icon indicating copy to clipboard operation
xFunc copied to clipboard

Wrap exceptions from BCL to custom xFunc exceptions

Open sys27 opened this issue 11 months ago • 0 comments

Any exception thrown by any method from the .NET standard library is returned as is. It is better to wrap them into custom xFunc exceptions: TokenizeException/ParseException/etc. and set InnerException to the original exception whenever it is possible.

Exceptions to wrap:

  • DivideByZeroException
  • FormatException
  • OverflowException
  • KeyNotFoundException
  • IndexOutOfRangeException
  • InvalidOperationException
  • NotSupportedException
  • ArgumentNullException?
  • ArgumentException?

See #766.

sys27 avatar Mar 01 '24 23:03 sys27