Skip to content

Commit 54e3f09

Browse files
Fix example for nullArg usage (#16044)
1 parent b682c35 commit 54e3f09

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/FSharp.Core/prim-types.fsi

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3477,8 +3477,8 @@ namespace Microsoft.FSharp.Core
34773477
/// <example id="nullarg-example">
34783478
/// <code lang="fsharp">
34793479
/// let fullName firstName lastName =
3480-
/// nullArg (nameof(firstName))
3481-
/// nullArg (nameof(lastName))
3480+
/// if isNull firstName then nullArg (nameof(firstName))
3481+
/// if isNull lastName then nullArg (nameof(lastName))
34823482
/// firstName + " " + lastName
34833483
///
34843484
/// fullName null "Jones" // Throws System.ArgumentNullException: Value cannot be null. (Parameter 'firstName')

0 commit comments

Comments
 (0)