63 |
|
#include "mdParser/MDParser.hpp" |
64 |
|
#include "mdParser/MDTreeParser.hpp" |
65 |
|
#include "mdParser/SimplePreprocessor.hpp" |
66 |
+ |
#include "antlr/ANTLRException.hpp" |
67 |
+ |
#include "antlr/TokenStreamRecognitionException.hpp" |
68 |
+ |
#include "antlr/TokenStreamIOException.hpp" |
69 |
+ |
#include "antlr/TokenStreamException.hpp" |
70 |
+ |
#include "antlr/RecognitionException.hpp" |
71 |
+ |
#include "antlr/CharStreamException.hpp" |
72 |
|
|
73 |
+ |
#include "antlr/MismatchedCharException.hpp" |
74 |
+ |
#include "antlr/MismatchedTokenException.hpp" |
75 |
+ |
#include "antlr/NoViableAltForCharException.hpp" |
76 |
+ |
#include "antlr/NoViableAltException.hpp" |
77 |
|
|
78 |
|
#ifdef IS_MPI |
79 |
|
#include "math/ParallelRandNumGen.hpp" |
102 |
|
streamSize = ppStream.str().size() +1; |
103 |
|
commStatus = MPI_Bcast(&streamSize, 1, MPI_LONG, masterNode, MPI_COMM_WORLD); |
104 |
|
|
105 |
< |
commStatus = MPI_Bcast(ppStream.str().c_str(), streamSize, MPI_CHAR, masterNode, MPI_COMM_WORLD); |
105 |
> |
commStatus = MPI_Bcast(static_cast<void*>(const_cast<char*>(ppStream.str().c_str())), streamSize, MPI_CHAR, masterNode, MPI_COMM_WORLD); |
106 |
|
|
107 |
|
|
108 |
|
} else { |
147 |
|
simParams = treeParser.walkTree(parser.getAST()); |
148 |
|
|
149 |
|
} |
150 |
+ |
|
151 |
+ |
catch(antlr::MismatchedCharException& e) { |
152 |
+ |
cerr<< "parser exception: " << e.getMessage() << " " << e.getFilename() << ":" << e.getLine() << " " << e.getColumn() << endl; |
153 |
+ |
} |
154 |
+ |
catch(antlr::MismatchedTokenException &e) { |
155 |
+ |
cerr<< "parser exception: " << e.getMessage() << " " << e.getFilename() << ":" << e.getLine() << " " << e.getColumn() << endl; |
156 |
+ |
} |
157 |
+ |
catch(antlr::NoViableAltForCharException &e) { |
158 |
+ |
cerr<< "parser exception: " << e.getMessage() << " " << e.getFilename() << ":" << e.getLine() << " " << e.getColumn() << endl; |
159 |
+ |
} |
160 |
+ |
catch(antlr::NoViableAltException &e) { |
161 |
+ |
cerr<< "parser exception: " << e.getMessage() << " " << e.getFilename() << ":" << e.getLine() << " " << e.getColumn() << endl; |
162 |
+ |
} |
163 |
+ |
catch(antlr::TokenStreamRecognitionException& e) { |
164 |
+ |
cerr<< "parser exception: " << e.getMessage() << " " << e.getFilename() << ":" << e.getLine() << " " << e.getColumn() << endl; |
165 |
+ |
} |
166 |
+ |
catch(antlr::TokenStreamIOException& e) { |
167 |
+ |
cerr<< "parser exception: " << e.getMessage() << endl; |
168 |
+ |
} |
169 |
+ |
catch(antlr::TokenStreamException& e) { |
170 |
+ |
cerr<< "parser exception: " << e.getMessage() << endl; |
171 |
+ |
} |
172 |
+ |
catch (antlr::RecognitionException& e) { |
173 |
+ |
cerr<< "parser exception: " << e.getMessage() << " " << e.getFilename() << ":" << e.getLine() << " " << e.getColumn() << endl; |
174 |
+ |
} |
175 |
+ |
catch (antlr::CharStreamException& e) { |
176 |
+ |
cerr << "parser exception: " << e.getMessage() << endl; |
177 |
+ |
} |
178 |
|
catch (exception& e) { |
179 |
|
cerr << "parser exception: " << e.what() << endl; |
180 |
|
} |
224 |
|
} |
225 |
|
|
226 |
|
ff->parse(forcefieldFileName); |
227 |
< |
|
227 |
> |
ff->setFortranForceOptions(); |
228 |
|
//create SimInfo |
229 |
|
SimInfo * info = new SimInfo(ff, simParams); |
230 |
|
|