Пример #1
0
 static bool HasBodyTokens(Dafny.Declaration decl)
 {
     Contract.Requires(decl != null);
     return(decl.BodyStartTok != Bpl.Token.NoToken && decl.BodyEndTok != Bpl.Token.NoToken);
 }
Пример #2
0
 public static void Error(Declaration d, string msg, params object[] args)
 {
     Contract.Requires(d != null);
     Contract.Requires(msg != null);
     Error(d.tok, msg, args);
 }
Пример #3
0
 public static void Error(Declaration d, string msg, params object[] args) {
     Contract.Requires(d != null);
     Contract.Requires(msg != null);
     Error(d.tok, msg, args);
 }
Пример #4
0
 /// <summary>
 /// Create an error message
 /// </summary>
 /// <param name="d">Declaration</param>
 /// <param name="n">error index</param>
 /// <param name="args">Optional string formating params</param>
 /// <returns>Error message</returns>
 public static string MkErr(Declaration d, int n, params object[] args)
 {
     Contract.Requires(d != null);
     return(MkErr(d.tok, n, args));
 }
Пример #5
0
 /// <summary>
 /// Create an error message 
 /// </summary>
 /// <param name="d">Declaration</param>
 /// <param name="n">error index</param>
 /// <param name="args">Optional string formating params</param>
 /// <returns>Error message</returns>
 public static string MkErr(Declaration d, int n, params object[] args) {
   Contract.Requires(d != null);
   return MkErr(d.tok, n, args);
 }