]> andersk Git - splint.git/blobdiff - src/cttable.i
Fixed all /*@i...@*/ tags (except 1).
[splint.git] / src / cttable.i
index dc1fcff1c5b6bb7401a814e4c07e7cab5d00bf6c..7613cb633570d79ff5f282db3471fb294f86f48d 100644 (file)
@@ -1,6 +1,6 @@
 /* ;-*-C-*-; 
 ** Splint - annotation-assisted static program checker
-** Copyright (C) 1994-2002 University of Virginia,
+** Copyright (C) 1994-2003 University of Virginia,
 **         Massachusetts Institute of Technology
 **
 ** This program is free software; you can redistribute it and/or modify it
@@ -286,19 +286,19 @@ cttable_print (void)
        {
          if (ctbase_isUA (cte->ctbase))
            {
-             fprintf (g_msgstream, "%3d: %s [%d]\n", i, 
+             fprintf (g_warningstream, "%3d: %s [%d]\n", i, 
                       cstring_toCharsSafe (ctentry_doUnparse (cttab.entries[i])),
                       cte->ctbase->contents.tid);
            }
          else
            {
-             fprintf (g_msgstream, "%3d: %s\n", i, 
+             fprintf (g_warningstream, "%3d: %s\n", i, 
                       cstring_toCharsSafe (ctentry_doUnparse (cttab.entries[i])));
            }
        }
       else
        {
-         /* fprintf (g_msgstream, "%3d: <no name>\n", i); */
+         /* fprintf (g_warningstream, "%3d: <no name>\n", i); */
        }
     }
   /*@noaccess ctbase@*/
@@ -319,17 +319,12 @@ cttable_dump (FILE *fout)
   
   if (context_getFlag (FLG_SHOWSCAN) && cttab.size > 5000)
     {
-      fprintf (g_msgstream, " >\n"); /* end dumping to */
-      fprintf (g_msgstream, "< Dumping type table (%d types) ", cttab.size);
+      displayScanClose ();
+      displayScanOpen (message ("Dumping type table (%d types)", cttab.size));
       showdotstride = cttab.size / 5;
       showdots = TRUE;
     }
 
-  /*
-  DPRINTF (("Dumping cttable: "));
-  cttable_print ();
-  */
-
   for (i = 0; i < cttab.size; i++)
     {
       cstring s;
@@ -342,15 +337,16 @@ cttable_dump (FILE *fout)
 
       if (showdots && (i != 0 && ((i - 1) % showdotstride == 0)))
        {
-         (void) fflush (g_msgstream);
-         fprintf (stderr, ".");
+         (void) fflush (g_warningstream);
+         displayScanContinue (cstring_makeLiteralTemp ("."));
          (void) fflush (stderr);
        }
     }
 
   if (showdots)
     {
-      fprintf (stderr, " >\n< Continuing dump ");
+      displayScanClose ();
+      displayScanOpen (cstring_makeLiteral ("Continuing dump "));
     }
   
 }
@@ -364,6 +360,7 @@ static void cttable_load (FILE *f)
   /*@modifies cttab, f @*/
 {
   char *s = mstring_create (MAX_DUMP_LINE_LENGTH);
+  char *os = s;
   ctentry cte;
 
   cttable_reset ();
@@ -387,7 +384,7 @@ static void cttable_load (FILE *f)
     {
       ctype ct;
 
-  /*drl bee: tcf*/      cte = ctentry_undump (s);
+      /*drl bee: tcf*/      cte = ctentry_undump (s);
       ct = cttable_addFull (cte);
 
       DPRINTF (("Type: %d: %s", ct, ctype_unparse (ct)));
@@ -398,10 +395,10 @@ static void cttable_load (FILE *f)
          ctype_recordConj (ct);
        }
 
-      (void) reader_readLine (f, s, MAX_DUMP_LINE_LENGTH);
+      s = reader_readLine (f, s, MAX_DUMP_LINE_LENGTH);
     }
 
-  sfree (s);
+  sfree (os);
 
   /*
   DPRINTF (("Done loading cttable: "));
@@ -544,7 +541,7 @@ cttable_addComplex (/*@only@*/ ctbase cnew)
          
          ctb = ctype_getCtbase (i);
          
-         /*@i32 is this optimization really worthwhile??? */
+         /* is this optimization really worthwhile? */
 
          if (ctbase_isDefined (ctb) && ctbase_equivStrict (cnew, ctb))
            {
This page took 0.364882 seconds and 4 git commands to generate.