Skip to content
This repository has been archived by the owner on Jul 15, 2023. It is now read-only.

Extend postcondition on Path.GetTempFileName #305

Merged
merged 1 commit into from
Nov 20, 2015

Conversation

yaakov-h
Copy link
Contributor

Extends postcondition to not-null or whitespace, and length >= 4 since it must end with ".TMP"

Resolves #298.

Extends postcondition to not-null or whitespace, and
length >= 4 since it must end with ".TMP"
SergeyTeplyakov added a commit that referenced this pull request Nov 20, 2015
Extend postcondition on Path.GetTempFileName
@SergeyTeplyakov SergeyTeplyakov merged commit 366e422 into microsoft:master Nov 20, 2015
@Daniel-Svensson
Copy link

The merge resutls in a build failure when invoking buildCC.bat

It seems like IsNullOrWhitespace is only awailible for .Net 4+ and Silverlight,
so maybe it should be replaced with IsNullOrEmpty or guireded by #if

"C:\Dev\CodeContracts\Microsoft.Research\ManagedContract.Setup\buildMSI10.xml" (All target) (1) ->
"C:\Dev\CodeContracts\CodeContracts.sln" (Clean;Rebuild target) (2) ->
"C:\Dev\CodeContracts\Microsoft.Research\Contracts\MsCorlib\MsCorlib.Contracts10.csproj.metaproj" (Rebuild target) (41:
3) ->
"C:\Dev\CodeContracts\Microsoft.Research\Contracts\MsCorlib\MsCorlib.Contracts10.csproj" (Rebuild target) (42:3) ->
(BuildMultiTargets target) ->
  CSC : warning CS8021: No value for RuntimeMetadataVersion found. No assembly containing System.Object was found nor w
as a value for RuntimeMetadataVersion specified through options. [C:\Dev\CodeContracts\Microsoft.Research\Contracts\MsC
orlib\MsCorlib.Contracts10.csproj]


"C:\Dev\CodeContracts\Microsoft.Research\ManagedContract.Setup\buildMSI10.xml" (All target) (1) ->
"C:\Dev\CodeContracts\CodeContracts.sln" (Clean;Rebuild target) (2) ->
"C:\Dev\CodeContracts\Microsoft.Research\Contracts\MsCorlib\MsCorlib.Contracts10.csproj.metaproj" (Rebuild target) (41:
3) ->
"C:\Dev\CodeContracts\Microsoft.Research\Contracts\MsCorlib\MsCorlib.Contracts10.csproj" (Rebuild target) (42:3) ->
(BuildMultiTargets target) ->
  System.IO.Path.cs(219,32): error CS0117: 'string' does not contain a definition for 'IsNullOrWhitespace' [C:\Dev\Code
Contracts\Microsoft.Research\Contracts\MsCorlib\MsCorlib.Contracts10.csproj]

@tom-englert
Copy link
Contributor

a) All other contracts in system.io use "IsNullOrEmpty" - we should not start using "IsNullOrWhitespace" now for no special reason.
b) Every second time someone changes contracts the build is broken because the change only builds on one specific platform - it should be common sense to try a build before pushing changes 😞

@SergeyTeplyakov
Copy link
Contributor

Ok. Without build automation, I'll kindly ask for the proof that build is working before merging PR.

@SergeyTeplyakov
Copy link
Contributor

I'll create a PR with a fix in a couple of minutes.

@SergeyTeplyakov
Copy link
Contributor

If someone will take a quick look, I'll merge the fix.

I've checked the build, It passed;)

@tom-englert
Copy link
Contributor

👍

@yaakov-h
Copy link
Contributor Author

Sorry about this. I forgot to verify this one.

Is anything happening with AppVeyor? I remember seeing something about that mentioned on another issue.

@yaakov-h yaakov-h deleted the pr-PathGetTempFileName branch November 21, 2015 09:54
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants