X-Git-Url: https://git.saurik.com/cycript.git/blobdiff_plain/c2c9f509581b8c8e78b5745498c782ef1affd51a..55c6d6ab933f1db37899604a17298cd6fc768fc3:/ObjectiveC/Output.mm diff --git a/ObjectiveC/Output.mm b/ObjectiveC/Output.mm index e406493..a2d765c 100644 --- a/ObjectiveC/Output.mm +++ b/ObjectiveC/Output.mm @@ -1,5 +1,5 @@ /* Cycript - Optimizing JavaScript Compiler/Runtime - * Copyright (C) 2009-2010 Jay Freeman (saurik) + * Copyright (C) 2009-2012 Jay Freeman (saurik) */ /* GNU Lesser General Public License, Version 3 {{{ */ @@ -75,6 +75,12 @@ void CYClassStatement::Output(CYOutput &out, CYFlags flags) const { CYClass::Output(out, flags); } +void CYEncodedType::Output(CYOutput &out, CYFlags flags) const { + out << "@encode("; + // XXX: this is seriously wrong + out << ")"; +} + void CYField::Output(CYOutput &out) const { } @@ -95,6 +101,19 @@ void CYMessage::Output(CYOutput &out, bool replace) const { out << code_; } +void CYBox::Output(CYOutput &out, CYFlags flags) const { + out << '@'; + value_->Output(out, Precedence(), CYRight(flags)); +} + +void CYObjCBlock::Output(CYOutput &out, CYFlags flags) const { + // XXX: this is seriously wrong + out << "^("; + out << ")"; + out << "{"; + out << "}"; +} + void CYProtocol::Output(CYOutput &out) const { name_->Output(out, CYAssign::Precedence_, CYNoFlags); if (next_ != NULL)