Skip to content

Commit 693167e

Browse files
committed
Add contract annotations
1 parent e36bc0c commit 693167e

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

source/Nuke.Common/Utilities/String.Emptiness.cs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,19 @@
22
// Distributed under the MIT License.
33
// https://github.com/nuke-build/nuke/blob/master/LICENSE
44

5+
using JetBrains.Annotations;
6+
57
namespace Nuke.Common.Utilities
68
{
79
public static partial class StringExtensions
810
{
11+
[ContractAnnotation("null => halt")]
912
public static bool IsNullOrEmpty(this string str)
1013
{
1114
return string.IsNullOrEmpty(str);
1215
}
1316

17+
[ContractAnnotation("null => halt")]
1418
public static bool IsNullOrWhiteSpace(this string str)
1519
{
1620
return string.IsNullOrWhiteSpace(str);

0 commit comments

Comments
 (0)