"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/reducer.cc" between
ragel-7.0.0.11.tar.gz and ragel-7.0.0.12.tar.gz

About: Ragel compiles executable finite state machines from regular languages (C, C++, Obj-C, C#, D, Java, Go and Ruby). Development version.

reducer.cc  (ragel-7.0.0.11):reducer.cc  (ragel-7.0.0.12)
skipping to change at line 32 skipping to change at line 32
#include "reducer.h" #include "reducer.h"
#include <colm/colm.h> #include <colm/colm.h>
#include <colm/tree.h> #include <colm/tree.h>
#include <errno.h> #include <errno.h>
using std::endl; using std::endl;
using std::ifstream; using std::ifstream;
extern colm_sections rl_parse;
void TopLevel::loadMachineName( string data ) void TopLevel::loadMachineName( string data )
{ {
/* Make/get the priority key. The name may have already been referenced /* Make/get the priority key. The name may have already been referenced
* and therefore exist. */ * and therefore exist. */
PriorDictEl *priorDictEl; PriorDictEl *priorDictEl;
if ( pd->priorDict.insert( data, pd->fsmCtx->nextPriorKey, &priorDictEl ) ) if ( pd->priorDict.insert( data, pd->fsmCtx->nextPriorKey, &priorDictEl ) )
pd->fsmCtx->nextPriorKey += 1; pd->fsmCtx->nextPriorKey += 1;
pd->curDefPriorKey = priorDictEl->value; pd->curDefPriorKey = priorDictEl->value;
skipping to change at line 212 skipping to change at line 211
const char **argv = new const char*[baseN + id->includePaths.length() + 1 ]; const char **argv = new const char*[baseN + id->includePaths.length() + 1 ];
argv[0] = cmd; argv[0] = cmd;
argv[1] = inputFileName; argv[1] = inputFileName;
for ( int i = 0; i < id->includePaths.length(); i++ ) for ( int i = 0; i < id->includePaths.length(); i++ )
argv[baseN + i] = id->includePaths.data[i]; argv[baseN + i] = id->includePaths.data[i];
argv[baseN + id->includePaths.length()] = 0; argv[baseN + id->includePaths.length()] = 0;
const char *prevCurFileName = curFileName; const char *prevCurFileName = curFileName;
curFileName = inputFileName; curFileName = inputFileName;
colm_program *program = colm_new_program( &rl_parse ); colm_program *program = colm_new_program( frontendSections );
colm_set_debug( program, 0 ); colm_set_debug( program, 0 );
colm_set_reduce_clean( program, 0 );
colm_set_reduce_ctx( program, this ); colm_set_reduce_ctx( program, this );
colm_run_program( program, baseN + id->includePaths.length(), argv ); colm_run_program( program, baseN + id->includePaths.length(), argv );
id->streamFileNames.append( colm_extract_fns( program ) ); id->streamFileNames.append( colm_extract_fns( program ) );
int length = 0; int length = 0;
const char *err = colm_error( program, &length ); const char *err = colm_error( program, &length );
if ( err != 0 ) { if ( err != 0 ) {
// std::cout << "error" << std::endl; // std::cout << "error" << std::endl;
id->error_plain() << string( err, length ) << std::endl; id->error_plain() << string( err, length ) << std::endl;
} }
 End of changes. 3 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)