summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorGravatar tabarbe <unknown>2010-08-27 00:29:15 +0000
committerGravatar tabarbe <unknown>2010-08-27 00:29:15 +0000
commit0faac5618039d3617b676c24e9465f712072adf3 (patch)
treeb68a85cabe8b8e655dfc517dfa8619f652995cfe /Source/Core
parentc8d7f1ce39b5b08ed6b5a5791393b8f25169d568 (diff)
Boogie: Graph port 3/3: Committing changed references; also, adding back cce files, to ease between-project conflict. Will trim these back off after commit of Basetypes port in ~20 min.
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Core.csproj5
-rw-r--r--Source/Core/cce.cs30
2 files changed, 21 insertions, 14 deletions
diff --git a/Source/Core/Core.csproj b/Source/Core/Core.csproj
index 54bc2cab..212e8208 100644
--- a/Source/Core/Core.csproj
+++ b/Source/Core/Core.csproj
@@ -92,6 +92,7 @@
<Compile Include="AbsyExpr.cs" />
<Compile Include="AbsyQuant.cs" />
<Compile Include="AbsyType.cs" />
+ <Compile Include="cce.cs" />
<Compile Include="CommandLineOptions.cs" />
<Compile Include="DeadVarElim.cs" />
<Compile Include="Duplicator.cs" />
@@ -121,8 +122,8 @@
<Project>{0C692837-77EC-415F-BF04-395E3ED06E9A}</Project>
<Name>Basetypes</Name>
</ProjectReference>
- <ProjectReference Include="..\Graph\Graph.sscproj">
- <Project>{4C28FB90-630E-4B55-A937-11A011B79765}</Project>
+ <ProjectReference Include="..\Graph\Graph.csproj">
+ <Project>{69A2B0B8-BCAC-4101-AE7A-556FCC58C06E}</Project>
<Name>Graph</Name>
</ProjectReference>
</ItemGroup>
diff --git a/Source/Core/cce.cs b/Source/Core/cce.cs
index 7aade95e..ef594484 100644
--- a/Source/Core/cce.cs
+++ b/Source/Core/cce.cs
@@ -3,7 +3,7 @@ using SA=System.Attribute;
using System.Collections.Generic;
using System.Diagnostics.Contracts;
using System.Text;
-using Microsoft.Boogie;
+//using Microsoft.Boogie;
/// <summary>
/// A class containing static methods to extend the functionality of Code Contracts
@@ -27,10 +27,10 @@ public static class cce {
public static bool NonNullElements<TKey, TValue>(IDictionary<TKey, TValue> collection) {
return collection != null && Contract.ForAll(collection, pair => NonNullElements(pair));
}
- [Pure]
- public static bool NonNullElements(VariableSeq collection) {
- return collection != null && Contract.ForAll(0, collection.Length, i => collection[i] != null);
- }
+ //[Pure]
+ //public static bool NonNullElements(VariableSeq collection) {
+ // return collection != null && Contract.ForAll(0, collection.Length, i => collection[i] != null);
+ //}
/// <summary>
/// For possibly-null lists of non-null elements
/// </summary>
@@ -123,13 +123,17 @@ public static class cce {
//public static bool IsValid(Microsoft.Dafny.Expression expression) {
// return true;
//}
- public static List<T> toList<T>(PureCollections.Sequence s) {
- List<T> toRet = new List<T>();
- foreach (T t in s.elems)
- if(t!=null)
- toRet.Add(t);
- return toRet;
- }
+ //public static List<T> toList<T>(PureCollections.Sequence s) {
+ // List<T> toRet = new List<T>();
+ // foreach (T t in s.elems)
+ // if(t!=null)
+ // toRet.Add(t);
+ // return toRet;
+ //}
+
+ //internal static bool NonNullElements(Set set) {
+ // return set != null && Contract.ForAll(0,set.Count, i => set[i] != null);
+ //}
}
public class PeerAttribute : SA {
@@ -184,4 +188,6 @@ public class SpecPublicAttribute : SA {
public class ElementsPeerAttribute : SA {
}
public class ResultNotNewlyAllocatedAttribute : SA {
+}
+public class OnceAttribute : SA {
} \ No newline at end of file