}
const char *CYDeclaration::ForEachIn() const {
- return identifier_->Value();
+ return identifier_->Word();
}
void CYDeclaration::ForIn(CYOutput &out, CYFlags flags) const {
}
void CYEmpty::Output(CYOutput &out, CYFlags flags) const {
+ out << '`';
out.Terminate();
}
void CYForIn::Output(CYOutput &out, CYFlags flags) const {
out << "for" << ' ' << '(';
- initialiser_->ForIn(out, CYNoIn);
+ if (initialiser_ != NULL)
+ initialiser_->ForIn(out, CYNoIn);
out << "in" << *set_ << ')';
code_->Single(out, CYRight(flags));
}
if (protect)
out << '(';
out << "function";
+ if (out.options_.verbose_)
+ out.out_ << ':' << static_cast<const CYScope *>(this);
if (name_ != NULL)
out << ' ' << *name_;
out << '(' << parameters_ << ')';
out << ',' << ' ' << *next_;
}
+const char *CYIdentifier::Word() const {
+ return replace_ == NULL || replace_ == this ? CYWord::Word() : replace_->Word();
+}
+
void CYIf::Output(CYOutput &out, CYFlags flags) const {
bool protect(false);
if (false_ == NULL && (flags & CYNoDangle) != 0) {
void CYWord::ClassName(CYOutput &out, bool object) const {
if (object)
out << "objc_getClass(";
- out << '"' << Value() << '"';
+ out << '"' << Word() << '"';
if (object)
out << ')';
}
void CYWord::Output(CYOutput &out) const {
- out << Value();
+ out << Word();
+ if (out.options_.verbose_)
+ out.out_ << '@' << this;
}
void CYWord::PropertyName(CYOutput &out) const {
Output(out);
}
+
+const char *CYWord::Word() const {
+ return word_;
+}