Skip to content

Commit f1ed66c

Browse files
authored
Merge pull request #540 from dotnet/master
Update live with current master
2 parents 202ce20 + 8ec44ff commit f1ed66c

File tree

9 files changed

+27
-181
lines changed

9 files changed

+27
-181
lines changed

.github/CODEOWNERS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@
1717
# C# samples:
1818
/csharp/** @BillWagner
1919

20+
# ML.NET samples:
21+
/machine-learning/** @JRAlexander
22+
2023
#### Snippets (under samples)
2124
# C++ snippets
2225
/snippets/cpp/** @rpetrusha

machine-learning/tutorials/IrisClustering.sln

Lines changed: 0 additions & 25 deletions
This file was deleted.

machine-learning/tutorials/IrisClustering/IrisClustering.csproj

Lines changed: 0 additions & 26 deletions
This file was deleted.

machine-learning/tutorials/IrisClustering/IrisData.cs

Lines changed: 0 additions & 32 deletions
This file was deleted.

machine-learning/tutorials/IrisClustering/Program.cs

Lines changed: 0 additions & 72 deletions
This file was deleted.

machine-learning/tutorials/IrisClustering/TestIrisData.cs

Lines changed: 0 additions & 17 deletions
This file was deleted.

snippets/csharp/VS_Snippets_Misc/wifcustomtokenst/cs/simplewebtoken/simplewebtoken.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,24 +28,24 @@ public class SimpleWebToken : SecurityToken
2828

2929
NameValueCollection _properties;
3030
//</Snippet3>
31-
string _serilaizedToken;
31+
string _serializedToken;
3232

3333
/// <summary>
3434
/// Initializes a new instance of the <see cref="SimpleWebToken"/> class.
35-
/// This is internal contructor is only called from the <see cref="SimpleWebTokenHandler"/> when reading a token received from the wire.
35+
/// This is an internal constructor that is only called from the <see cref="SimpleWebTokenHandler"/> when reading a token received from the wire.
3636
/// </summary>
37-
/// <param name="properties">The collection represents all the key value pairs in the token.</param>
37+
/// <param name="properties">The collection representing all the key value pairs in the token.</param>
3838
/// <param name="serializedToken">The serialized form of the token.</param>
3939
internal SimpleWebToken( NameValueCollection properties, string serializedToken )
4040
: this(properties)
4141
{
42-
_serilaizedToken = serializedToken;
42+
_serializedToken = serializedToken;
4343
}
4444

4545
/// <summary>
4646
/// Initializes a new instance of the <see cref="SimpleWebToken"/> class.
4747
/// </summary>
48-
/// <param name="properties">The collection represents all the key value pairs in the token.</param>
48+
/// <param name="properties">The collection representing all the key value pairs in the token.</param>
4949
public SimpleWebToken( NameValueCollection properties )
5050
{
5151
if ( properties == null )
@@ -103,7 +103,7 @@ public override DateTime ValidFrom
103103
/// <summary>
104104
/// Gets the time when the token expires.
105105
/// </summary>
106-
/// <value>The time upto which the token is valid.</value>
106+
/// <value>The time up to which the token is valid.</value>
107107
public override DateTime ValidTo
108108
{
109109
get
@@ -158,7 +158,7 @@ public string SerializedToken
158158
{
159159
get
160160
{
161-
return _serilaizedToken;
161+
return _serializedToken;
162162
}
163163
}
164164

@@ -173,7 +173,7 @@ public NameValueCollection GetAllProperties()
173173

174174
//<Snippet8>
175175
/// <summary>
176-
/// Convert the time in seconds to a <see cref="DateTime"/> object based on the base time
176+
/// Converts the time in seconds to a <see cref="DateTime"/> object based on the base time
177177
/// defined by the Simple Web Token.
178178
/// </summary>
179179
/// <param name="expiryTime">The time in seconds.</param>

snippets/csharp/concepts/lambda-expressions/tuples2.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ public class Example
77
public static void Main()
88
{
99
var numbers = (2, 3, 4, 5, 6);
10-
Func<(int n1, int n2, int n3, int n4, int n5), (int, int, int, int, int)> doubleThem = (n) => (n.n1 * 2, n2 * 2, n.n3 * 2, n.n4 * 2, n.n5 * 2);
10+
Func<(int n1, int n2, int n3, int n4, int n5), (int, int, int, int, int)> doubleThem = (n) => (n.n1 * 2, n.n2 * 2, n.n3 * 2, n.n4 * 2, n.n5 * 2);
1111
var doubledNumbers = doubleThem(numbers);
1212

1313
Console.WriteLine("The set {0} doubled: {1}", numbers, doubledNumbers);
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
```fsharp
2+
[<Struct>]
3+
type Foo =
4+
val mutable bar: string
5+
member self.ChangeBar bar = self.bar <- bar
6+
new (bar) = {bar = bar}
7+
8+
let foo = Foo "1"
9+
foo.ChangeBar "2" //make implicit copy of Foo, changes the copy, discards the copy, foo remains unchanged
10+
printfn "%s" foo.bar //prints 1
11+
12+
let mutable foo' = Foo "1"
13+
foo'.ChangeBar "2" //changes foo'
14+
printfn "%s" foo'.bar //prints 2
15+
```

0 commit comments

Comments
 (0)