diff options
author | Rustan Leino <leino@microsoft.com> | 2012-10-04 13:32:50 -0700 |
---|---|---|
committer | Rustan Leino <leino@microsoft.com> | 2012-10-04 13:32:50 -0700 |
commit | 8911e5c95d4715c2e2626aef67f19793d6f43201 (patch) | |
tree | d703bfd931802e780430e32f1339cf77adc342a4 /Source/Dafny/Util.cs | |
parent | 1c375d1889e628fcd2a1a0fc041673a5f4230d84 (diff) |
Put all sources under \Source directory
Diffstat (limited to 'Source/Dafny/Util.cs')
-rw-r--r-- | Source/Dafny/Util.cs | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/Source/Dafny/Util.cs b/Source/Dafny/Util.cs new file mode 100644 index 00000000..8db3ebc8 --- /dev/null +++ b/Source/Dafny/Util.cs @@ -0,0 +1,20 @@ +using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+
+namespace Microsoft.Dafny {
+ class Util
+ {
+ public delegate string ToString<T>(T t);
+ public static string Comma<T>(string comma, IEnumerable<T> l, ToString<T> f) {
+ string res = "";
+ string c = "";
+ foreach(var t in l) {
+ res += c + f(t);
+ c = comma;
+ }
+ return res;
+ }
+ }
+}
|