mojoshader_preprocessor.c
changeset 683 54b8cf85b9b9
parent 682 ad75eb06ddce
child 684 aadf9aad508a
equal deleted inserted replaced
682:ad75eb06ddce 683:54b8cf85b9b9
  1432 
  1432 
  1433     #undef ADD_TO_OUTPUT
  1433     #undef ADD_TO_OUTPUT
  1434     #undef PUSH_TO_STACK
  1434     #undef PUSH_TO_STACK
  1435 
  1435 
  1436     // okay, you now have some validated data in reverse polish notation.
  1436     // okay, you now have some validated data in reverse polish notation.
  1437     printf("RPN:");
  1437     #if DEBUG_PREPROCESSOR
       
  1438     printf("EXPRESSION RPN:");
  1438     int i = 0;
  1439     int i = 0;
  1439     for (i = 0; i < outputsize; i++)
  1440     for (i = 0; i < outputsize; i++)
  1440     {
  1441     {
  1441         if (!output[i].isoperator)
  1442         if (!output[i].isoperator)
  1442             printf(" %d", output[i].value);
  1443             printf(" %d", output[i].value);
  1457                 default: printf(" %c", output[i].value); break;
  1458                 default: printf(" %c", output[i].value); break;
  1458             } // switch
  1459             } // switch
  1459         } // else
  1460         } // else
  1460     } // for
  1461     } // for
  1461     printf("\n");
  1462     printf("\n");
       
  1463     #endif
       
  1464 
  1462     return 1;
  1465     return 1;
  1463 } // reduce_pp_expression
  1466 } // reduce_pp_expression
  1464 
  1467 
  1465 
  1468 
  1466 static Conditional *handle_pp_if(Context *ctx)
  1469 static Conditional *handle_pp_if(Context *ctx)