mojoshader_compiler.c
changeset 945 f00ea3986db8
parent 940 bc2a5efade5e
child 958 02e7826c8c75
--- a/mojoshader_compiler.c	Tue Nov 09 05:00:03 2010 -0500
+++ b/mojoshader_compiler.c	Tue Nov 09 05:05:41 2010 -0500
@@ -2368,7 +2368,7 @@
     retval->malloc = (ctx->malloc == MOJOSHADER_internal_malloc) ? NULL : ctx->malloc;
     retval->free = (ctx->free == MOJOSHADER_internal_free) ? NULL : ctx->free;
     retval->malloc_data = ctx->malloc_data;
-    retval->error_count = ctx->errors->count;
+    retval->error_count = errorlist_count(ctx->errors);
     retval->errors = errorlist_flatten(ctx->errors);
 
     if (ctx->out_of_memory)
@@ -2403,7 +2403,7 @@
         retval->ast = ctx->ast;
     } // if
 
-    retval->error_count = ctx->errors->count;
+    retval->error_count = errorlist_count(ctx->errors);
     retval->errors = errorlist_flatten(ctx->errors);
     if (ctx->out_of_memory)
     {
@@ -2462,9 +2462,9 @@
     retval->free = (ctx->free == MOJOSHADER_internal_free) ? NULL : ctx->free;
     retval->malloc_data = ctx->malloc_data;
     retval->source_profile = ctx->source_profile;
-    retval->error_count = ctx->errors->count;
+    retval->error_count = errorlist_count(ctx->errors);
     retval->errors = errorlist_flatten(ctx->errors);
-    retval->warning_count = ctx->warnings->count;
+    retval->warning_count = errorlist_count(ctx->warnings);
     retval->warnings = errorlist_flatten(ctx->warnings);
 
     if (ctx->out_of_memory)  // in case something failed up there.
@@ -2503,9 +2503,9 @@
         // !!! FIXME: build symbols and symbol_count here.
     } // if
 
-    retval->error_count = ctx->errors->count;
+    retval->error_count = errorlist_count(ctx->errors);
     retval->errors = errorlist_flatten(ctx->errors);
-    retval->warning_count = ctx->warnings->count;
+    retval->warning_count = errorlist_count(ctx->warnings);
     retval->warnings = errorlist_flatten(ctx->warnings);
 
     if (ctx->out_of_memory)  // in case something failed up there.