public static void cppOutputStatement(Stella_Object statement) {
    if (Stella_Object.safePrimaryType(statement) == Stella.SGT_STELLA_CONS) {
      { Cons statement000 = ((Cons)(statement));

        if (statement000 == Stella.NIL) {
          return;
        }
        if (Stella_Object.consP(statement000.value) ||
            (statement000.value == null)) {
          {
            Stella_Object.cppOutputStatement(statement000.value);
            Stella_Object.cppOutputStatement(statement000.rest);
          }
        }
        else {
          { GeneralizedSymbol testValue000 = ((GeneralizedSymbol)(statement000.value));

            if (testValue000 == Stella.SYM_STELLA_CPP_COMMENT) {
              StringWrapper.cppOutputComment(((StringWrapper)(statement000.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_CLASS) {
              Cons.cppOutputClass(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_HANDLER_CASE) {
              Cons.cppOutputHandlerCase(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_CATCH) {
              Cons.cppOutputCatch(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_SIGNAL) {
              Cons.cppOutputSignal(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_UNWIND_PROTECT) {
              Cons.cppOutputUnwindProtect(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_VERBATIM) {
              StringWrapper.cppOutputVerbatim(((StringWrapper)(statement000.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_CAST) {
              Cons.cppOutputCast(statement000.rest);
            }
            else if ((testValue000 == Stella.SYM_STELLA_CPP_GLOBAL) ||
                ((testValue000 == Stella.SYM_STELLA_CPP_SPECIAL) ||
                 (testValue000 == Stella.SYM_STELLA_CPP_LOCAL))) {
              Cons.cppOutputVariableDefinition(statement000);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_TYPE) {
              Cons.cppOutputTypeExpression(((Cons)(statement000.rest)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_DEREFERENCE) {
              Cons.cppOutputDereference(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_ARRAY_REFERENCE) {
              Cons.cppOutputArrayReference(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_PROGN) {
              Cons.cppOutputProgn(((Cons)(statement000.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_WITH_PROCESS_LOCK) {
              Cons.cppOutputWithProcessLock(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_BREAK) {
              Stella.cppOutputBreak();
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_CONTINUE) {
              Stella.cppOutputContinue();
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_IF) {
              Cons.cppOutputIf(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_FUNCTION_SIGNATURE) {
              Cons.cppOutputFuncallFunctionSignature(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_METHOD_SIGNATURE) {
              Cons.cppOutputMethodCodeCallSignature(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_COND) {
              Cons.cppOutputCond(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_CASE) {
              Cons.cppOutputCase(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_WHEN) {
              Cons.cppOutputWhen(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_UNLESS) {
              Cons.cppOutputUnless(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_ASSIGN) {
              Cons.cppOutputAssignment(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_LOOP) {
              Cons.cppOutputLoop(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_WHILE) {
              Cons.cppOutputWhile(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_FOREACH) {
              Cons.cppOutputForeach(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_BLOCK) {
              Cons.cppOutputBlock(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_IDENT) {
              StringWrapper.cppOutputIdentifier(((StringWrapper)(statement000.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_PRINT_STREAM) {
              Cons.cppOutputPrintStream(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_PRINT_NATIVE_STREAM) {
              Cons.cppOutputPrintNativeStream(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_LITERAL) {
              statement000.rest.value.cppOutputLiteral();
            }
            else if ((testValue000 == Stella.SYM_STELLA_CPP_FUNCTION) ||
                (testValue000 == Stella.SYM_STELLA_CPP_METHOD)) {
              Cons.cppOutputFunction(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_RETURN) {
              Cons.cppOutputReturn(((Cons)(statement000.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_SYMBOL) {
              statement000.rest.value.cppOutputLiteral();
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_MAKE) {
              Cons.cppOutputMake(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_FUNCALL) {
              Cons.cppOutputFuncall(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_METHOD_CODE_CALL) {
              Cons.cppOutputMethodCodeCall(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_FUNCTION_POINTER) {
              StringWrapper.cppOutputFunctionPointer(((StringWrapper)(statement000.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_METHOD_POINTER) {
              StringWrapper.cppOutputMethodPointer(((StringWrapper)(statement000.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_SLOT_VALUE) {
              Cons.cppOutputSlotValue(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_REFERENCED_SLOT_VALUE) {
              Cons.cppOutputReferencedSlotValue(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_SLOT_VALUE_SETTER) {
              Cons.cppOutputSlotValueSetter(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_DECLARATIONS) {
              Keyword.cppOutputDeclarations(((Keyword)(statement000.rest.value)), ((Cons)(statement000.rest.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_DEFINITIONS) {
              Keyword.cppOutputDefinitions(((Keyword)(statement000.rest.value)), ((Cons)(statement000.rest.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_SIGNATURES) {
              Keyword.cppOutputSignatures(((Keyword)(statement000.rest.value)), ((Cons)(statement000.rest.rest.value)));
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_STATEMENTS) {
              Cons.cppOutputStatements(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_UNARY_OP) {
              Cons.cppOutputUnaryOperator(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_BINARY_OP) {
              Cons.cppOutputBinaryOperator(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_TERNARY_OP) {
              Cons.cppOutputTernaryOperator(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_FUNCTION_CALL) {
              Cons.cppOutputFunctionCall(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_METHOD_SETTER_CALL) {
              Cons.cppOutputMethodSetterCall(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_METHOD_CALL) {
              Cons.cppOutputMethodCall(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_REFERENCED_METHOD_CALL) {
              Cons.cppOutputReferencedMethodCall(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_ACTUALS) {
              Cons.cppOutputActualParameters(statement000.rest);
            }
            else if (testValue000 == Stella.SYM_STELLA_CPP_DEFPRINT) {
              Cons.cppOutputDefprint(statement000.rest);
            }
            else {
              { OutputStringStream stream000 = OutputStringStream.newOutputStringStream();

                stream000.nativeStream.print("`" + testValue000 + "' is not a valid case option");
                throw ((StellaException)(StellaException.newStellaException(stream000.theStringReader()).fillInStackTrace()));
              }
            }
          }
        }
      }
    }
    else {
      if (statement == null) {
        return;
      }
      Stella_Object.cppOutputAtomicExpression(statement);
    }
  }