You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We can potentially create Roslyn Analysers to detect common issues when people are using the runtime library or generated code. Examples of problems we can detect are:
Returning null from a service method.
Throwing an exception that isn't part of the service method definition.
To illustrate this, let's take the example of returning null from a service method. Thrift doesn't support null return results from service methods, and has no way to serialise that. So if someone writes the following code:
We can report an error when returning null since we know that it isn't a valid return result.
An example of a project that provides analysers like this is xUnit. It can detect problems like Theories not having the correct parameters passed to them at compile time, something that would typically cause a runtime error.
The text was updated successfully, but these errors were encountered:
adam-resdiary
added
the
type/epic
Used to describe a larger chunk of work that will need to be broken down into further tasks
label
Oct 7, 2020
We can potentially create Roslyn Analysers to detect common issues when people are using the runtime library or generated code. Examples of problems we can detect are:
null
from a service method.To illustrate this, let's take the example of returning
null
from a service method. Thrift doesn't supportnull
return results from service methods, and has no way to serialise that. So if someone writes the following code:We can report an error when returning null since we know that it isn't a valid return result.
An example of a project that provides analysers like this is xUnit. It can detect problems like Theories not having the correct parameters passed to them at compile time, something that would typically cause a runtime error.
The text was updated successfully, but these errors were encountered: