Exemple #1
0
UnimplementedOpcode::UnimplementedOpcode(
    RLMachine& machine,
    const libReallive::CommandElement& command)
    : Exception(""),
      has_parameters_(true),
      parameters_(command.getUnparsedParameters()) {
    ostringstream oss;
    oss << "opcode<" << command.modtype() << ":" << command.module() << ":"
        << command.opcode() << ", " << command.overload() << ">";
    name_ = oss.str();
    setFullDescription(machine);
}
Exemple #2
0
void RLOp_SpecialCase::dispatchFunction(RLMachine& machine,
                                        const libReallive::CommandElement& ff) {
  // First try to run the default parse_parameters if we can.
  if (!ff.areParametersParsed()) {
    vector<string> unparsed = ff.getUnparsedParameters();
    libReallive::ExpressionPiecesVector output;
    parseParameters(unparsed, output);
    ff.setParsedParameters(output);
  }

  // Pass this on to the implementation of this functor.
  operator()(machine, ff);
}