Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix example #137

Merged
merged 1 commit into from
May 3, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions _pages/1200_MiscellaneousDesignGuidelines.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ When throwing or handling exceptions in code that uses `async`/`await` or a `Tas
An event that has no subscribers is `null`. So before invoking, always make sure that the delegate list represented by the event variable is not `null`.
Invoke using the null conditional operator, because it additionally prevents conflicting changes to the delegate list from concurrent threads.

event EventHandler Notify;
protected virtual void OnNotify(NotifyEventArgs args)
event EventHandler<NotifyEventArgs> Notify;

protected virtual void OnNotify(NotifyEventArgs args)
{
Notify?.Invoke(this, args);
}
Expand Down Expand Up @@ -84,7 +84,7 @@ Instead of casting to and from the object type in generic types or methods, use
### <a name="av1250"></a> Evaluate the result of a LINQ expression before returning it (AV1250) ![](/assets/images/1.png)

Consider the following code snippet

public IEnumerable GetGoldMemberCustomers()
{
const decimal GoldMemberThresholdInEuro = 1_000_000;
Expand Down