8000 Added Code Contracts into the LibGit2Sharp project. · scrum-software/libgit2sharp@7f1d36d · GitHub
[go: up one dir, main page]

Skip to content

Commit 7f1d36d

Browse files
committed
Added Code Contracts into the LibGit2Sharp project.
This was done to remove code analysis warnings.
1 parent d535976 commit 7f1d36d

File tree

1 file changed

+87
-0
lines changed

1 file changed

+87
-0
lines changed

LibGit2Sharp/LibGit2Sharp.csproj

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
1414
<FileAlignment>512</FileAlignment>
1515
<TargetFrameworkProfile />
16+
<CodeContractsAssemblyMode>1</CodeContractsAssemblyMode>
1617
</PropertyGroup>
1718
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
1819
<DebugSymbols>true</DebugSymbols>
@@ -26,6 +27,49 @@
2627
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
2728
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
2829
<DocumentationFile>bin\Debug\LibGit2Sharp.xml</DocumentationFile>
30+
<CodeContractsEnableRuntimeChecking>True</CodeContractsEnableRuntimeChecking>
31+
<CodeContractsRuntimeOnlyPublicSurface>False</CodeContractsRuntimeOnlyPublicSurface>
32+
<CodeContractsRuntimeThrowOnFailure>True</CodeContractsRuntimeThrowOnFailure>
33+
<CodeContractsRuntimeCallSiteRequires>False</CodeContractsRuntimeCallSiteRequires>
34+
<CodeContractsRuntimeSkipQuantifiers>False</CodeContractsRuntimeSkipQuantifiers>
35+
<CodeContractsRunCodeAnalysis>False</CodeContractsRunCodeAnalysis>
36+
<CodeContractsNonNullObligations>True</CodeContractsNonNullObligations>
37+
<CodeContractsBoundsObligations>True</CodeContractsBoundsObligations>
38+
<CodeContractsArithmeticObligations>True</CodeContractsArithmeticObligations>
39+
<CodeContractsEnumObligations>True</CodeContractsEnumObligations>
40+
<CodeContractsRedundantAssumptions>True</CodeContractsRedundantAssumptions>
41+
<CodeContractsAssertsToContractsCheckBox>True</CodeContractsAssertsToContractsCheckBox>
42+
<CodeContractsRedundantTests>True</CodeContractsRedundantTests>
43+
<CodeContractsMissingPublicRequiresAsWarnings>True</CodeContractsMissingPublicRequiresAsWarnings>
44+
<CodeContractsMissingPublicEnsuresAsWarnings>False</CodeContractsMissingPublicEnsuresAsWarnings>
45+
<CodeContractsInferRequires>True</CodeContractsInferRequires>
46+
<CodeContractsInferEnsures>False</CodeContractsInferEnsures>
47+
<CodeContractsInferEnsuresAutoProperties>True</CodeContractsInferEnsuresAutoProperties>
48+
<CodeContractsInferObjectInvariants>False</CodeContractsInferObjectInvariants>
49+
<CodeContractsSuggestAssumptions>False</CodeContractsSuggestAssumptions>
50+
<CodeContractsSuggestAssumptionsForCallees>False</CodeContractsSuggestAssumptionsForCallees>
51+
<CodeContractsSuggestRequires>False</CodeContractsSuggestRequires>
52+
<CodeContractsNecessaryEnsures>True</CodeContractsNecessaryEnsures>
53+
<CodeContractsSuggestObjectInvariants>False</CodeContractsSuggestObjectInvariants>
54+
<CodeContractsSuggestReadonly>True</CodeContractsSuggestReadonly>
55+
<CodeContractsRunInBackground>True</CodeContractsRunInBackground>
56+
<CodeContractsShowSquigglies>True</CodeContractsShowSquigglies>
57+
<CodeContractsUseBaseLine>False</CodeContractsUseBaseLine>
58+
<CodeContractsEmitXMLDocs>False</CodeContractsEmitXMLDocs>
59+
<CodeContractsCustomRewriterAssembly />
60+
<CodeContractsCustomRewriterClass />
61+
<CodeContractsLibPaths />
62+
<CodeContractsExtraRewriteOptions />
63+
<CodeContractsExtraAnalysisOptions />
64+
<CodeContractsSQLServerOption />
65+
<CodeContractsBaseLineFile />
66+
<CodeContractsCacheAnalysisResults>True</CodeContractsCacheAnalysisResults>
67+
<CodeContractsSkipAnalysisIfCannotConnectToCache>False</CodeContractsSkipAnalysisIfCannotConnectToCache>
68+
<CodeContractsFailBuildOnWarnings>False</CodeContractsFailBuildOnWarnings>
69+
<CodeContractsBeingOptimisticOnExternal>True</CodeContractsBeingOptimisticOnExternal>
70+
<CodeContractsRuntimeCheckingLevel>Full</CodeContractsRuntimeCheckingLevel>
71+
<CodeContractsReferenceAssembly>DoNotBuild</CodeContractsReferenceAssembly>
72+
<CodeContractsAnalysisWarningLevel>0</CodeContractsAnalysisWarningLevel>
2973
</PropertyGroup>
3074
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
3175
<DebugType>pdbonly</DebugType>
@@ -38,6 +82,49 @@
3882
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
3983
<DocumentationFile>bin\Release\LibGit2Sharp.xml</DocumentationFile>
4084
<CodeAnalysisIgnoreGeneratedCode>true</CodeAnalysisIgnoreGeneratedCode>
85+
<CodeContractsEnableRuntimeChecking>True</CodeContractsEnableRuntimeChecking>
86+
<CodeContractsRuntimeOnlyPublicSurface>False</CodeContractsRuntimeOnlyPublicSurface>
87+
<CodeContractsRuntimeThrowOnFailure>True</CodeContractsRuntimeThrowOnFailure>
88+
<Co 8000 deContractsRuntimeCallSiteRequires>False</CodeContractsRuntimeCallSiteRequires>
89+
<CodeContractsRuntimeSkipQuantifiers>False</CodeContractsRuntimeSkipQuantifiers>
90+
<CodeContractsRunCodeAnalysis>False</CodeContractsRunCodeAnalysis>
91+
<CodeContractsNonNullObligations>True</CodeContractsNonNullObligations>
92+
<CodeContractsBoundsObligations>True</CodeContractsBoundsObligations>
93+
<CodeContractsArithmeticObligations>True</CodeContractsArithmeticObligations>
94+
<CodeContractsEnumObligations>True</CodeContractsEnumObligations>
95+
<CodeContractsRedundantAssumptions>True</CodeContractsRedundantAssumptions>
96+
<CodeContractsAssertsToContractsCheckBox>True</CodeContractsAssertsToContractsCheckBox>
97+
<CodeContractsRedundantTests>True</CodeContractsRedundantTests>
98+
<CodeContractsMissingPublicRequiresAsWarnings>True</CodeContractsMissingPublicRequiresAsWarnings>
99+
<CodeContractsMissingPublicEnsuresAsWarnings>False</CodeContractsMissingPublicEnsuresAsWarnings>
100+
<CodeContractsInferRequires>True</CodeContractsInferRequires>
101+
<CodeContractsInferEnsures>False</CodeContractsInferEnsures>
102+
<CodeContractsInferEnsuresAutoProperties>True</CodeContractsInferEnsuresAutoProperties>
103+
<CodeContractsInferObjectInvariants>False</CodeContractsInferObjectInvariants>
104+
<CodeContractsSuggestAssumptions>False</CodeContractsSuggestAssumptions>
105+
<CodeContractsSuggestAssumptionsForCallees>False</CodeContractsSuggestAssumptionsForCallees>
106+
<CodeContractsSuggestRequires>False</CodeContractsSuggestRequires>
107+
<CodeContractsNecessaryEnsures>True</CodeContractsNecessaryEnsures>
108+
<CodeContractsSuggestObjectInvariants>False</CodeContractsSuggestObjectInvariants>
109+
<CodeContractsSuggestReadonly>True</CodeContractsSuggestReadonly>
110+
<CodeContractsRunInBackground>True</CodeContractsRunInBackground>
111+
<CodeContractsShowSquigglies>True</CodeContractsShowSquigglies>
112+
<CodeContractsUseBaseLine>False</CodeContractsUseBaseLine>
113+
<CodeContractsEmitXMLDocs>False</CodeContractsEmitXMLDocs>
114+
<CodeContractsCustomRewriterAssembly />
115+
<CodeContractsCustomRewriterClass />
116+
<CodeContractsLibPaths />
117+
<CodeContractsExtraRewriteOptions />
118+
<CodeContractsExtraAnalysisOptions />
119+
<CodeContractsSQLServerOption />
120+
<CodeContractsBaseLineFile />
121+
<CodeContractsCacheAnalysisResults>True</CodeContractsCacheAnalysisResults>
122+
<CodeContractsSkipAnalysisIfCannotConnectToCache>False</CodeContractsSkipAnalysisIfCannotConnectToCache>
123+
<CodeContractsFailBuildOnWarnings>False</CodeContractsFailBuildOnWarnings>
124+
<CodeContractsBeingOptimisticOnExternal>True</CodeContractsBeingOptimisticOnExternal>
125+
<CodeContractsRuntimeCheckingLevel>Full</CodeContractsRuntimeCheckingLevel>
126+
<CodeContractsReferenceAssembly>DoNotBuild</CodeContractsReferenceAssembly>
127+
<CodeContractsAnalysisWarningLevel>0</CodeContractsAnalysisWarningLevel>
41128
</PropertyGroup>
42129
<PropertyGroup>
43130
<SignAssembly>true</SignAssembly>

0 commit comments

Comments
 (0)
0