Skip to content

Commit 696c608

Browse files
author
Ruben Schmidmeister
authored
Merge pull request #36 from messerli-informatik-ag/add-links
Add links to .NET docs
2 parents 1078002 + a3dde59 commit 696c608

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

documentation/src/basic-constructs.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,9 @@ foreach (var value in values.OrderByDescending(v => v))
5757

5858
### Handle all cases
5959

60-
Unhandled cases lead the program into an undefined state. If you have no natural default case, declare one throwing a System.NotImplementedException.
60+
Unhandled cases lead the program into an undefined state. If you have no natural default case, declare one throwing a [System.NotImplementedException].
61+
62+
[System.NotImplementedException]: https://docs.microsoft.com/en-us/dotnet/api/system.notimplementedexception
6163

6264
## Goto
6365

documentation/src/expressions.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ return condition
3838

3939
## Switch Expression
4040

41-
Prefer switch expressions over switch statements.
41+
Prefer [switch expressions] over switch statements.
4242

4343
```csharp
4444
return animalKind switch
@@ -50,9 +50,11 @@ return animalKind switch
5050
```
5151
*switch expression*
5252

53+
[switch expressions]: https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/operators/switch-expression
54+
5355
## Expression-bodied Members
5456

55-
Use the expression body syntax when a member returns a single expression.
57+
Use the [expression body syntax] when a member returns a single expression.
5658
Move the arrow to the next line when the expression gets too long.
5759

5860
```csharp
@@ -62,3 +64,5 @@ public string AbsolutePath()
6264
=> Path.Combine(CalculateRootPath(), RelativePath);
6365
```
6466
*expression-bodied members*
67+
68+
[expression body syntax]: https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/statements-expressions-operators/expression-bodied-members

0 commit comments

Comments
 (0)