#include <YCode.h>

| enum YCode::ykind |
| YCode::YCode | ( | ) |
Creates a new YCode element
| YCode::~YCode | ( | ) | [virtual] |
Cleans up
| YCode::REP_BODY | ( | YCode | ) | [private] |
| virtual ykind YCode::kind | ( | ) | const [pure virtual] |
Returns the YCode kind
Implemented in YBlock, YConst, YLocale, YFunction, YEVariable, YEReference, YETerm, YECompare, YELocale, YEList, YEMap, YEPropagate, YEUnary, YEBinary, YETriple, YEIs, YEReturn, YEBracket, YEBuiltin, YEFunction, YEFunctionPointer, YSBreak, YSContinue, YSExpression, YSBlock, YSReturn, YSTypedef, YSFunction, YSAssign, YSVariable, YSBracket, YSIf, YSWhile, YSRepeat, YSDo, YSTextdomain, YSInclude, YSImport, YSFilename, and YSSwitch.
Referenced by YStatement::toStream(), toStream(), toString(), toXml(), and YStatement::YStatement().
| string YCode::toString | ( | void | ) | const [virtual] |
Returns an ASCII representation of the YCode.
Reimplemented in YBlock, YConst, YLocale, YFunction, YEVariable, YEReference, YETerm, YECompare, YELocale, YEList, YEMap, YEPropagate, YEUnary, YEBinary, YETriple, YEIs, YEReturn, YEBracket, YEBuiltin, YECall, YStatement, YSBreak, YSContinue, YSExpression, YSBlock, YSReturn, YSTypedef, YSFunction, YSAssign, YSVariable, YSBracket, YSIf, YSWhile, YSRepeat, YSDo, YSTextdomain, YSInclude, YSImport, YSFilename, and YSSwitch.
References kind().
Referenced by YEBuiltin::evaluate(), evaluate(), Bytecode::readValue(), toStream(), toXml(), and YConst::YConst().
| std::ostream & YCode::toStream | ( | std::ostream & | str | ) | const [pure virtual] |
writes YCode to a stream see Bytecode for read
Implemented in YBlock, YConst, YLocale, YFunction, YEVariable, YEReference, YETerm, YECompare, YELocale, YEList, YEMap, YEPropagate, YEUnary, YEBinary, YETriple, YEIs, YEReturn, YEBracket, YEBuiltin, YECall, YStatement, YSBreak, YSContinue, YSExpression, YSBlock, YSReturn, YSTypedef, YSFunction, YSAssign, YSBracket, YSIf, YSWhile, YSRepeat, YSDo, YSTextdomain, YSInclude, YSImport, YSFilename, and YSSwitch.
References kind(), toString(), and y2debug.
Referenced by YStatement::toStream(), YECall::toStream(), YEBuiltin::toStream(), YEBracket::toStream(), YEReturn::toStream(), YEIs::toStream(), YETriple::toStream(), YEBinary::toStream(), YEUnary::toStream(), YEPropagate::toStream(), YEMap::toStream(), YEList::toStream(), YELocale::toStream(), YECompare::toStream(), YETerm::toStream(), YEReference::toStream(), YEVariable::toStream(), YFunction::toStream(), YLocale::toStream(), YConst::toStream(), and YBlock::toStream().
| std::ostream & YCode::toXml | ( | std::ostream & | str, | |
| int | indent | |||
| ) | const [pure virtual] |
Implemented in YBlock, YConst, YLocale, YFunction, YEVariable, YEReference, YETerm, YECompare, YELocale, YEList, YEMap, YEPropagate, YEUnary, YEBinary, YETriple, YEIs, YEReturn, YEBracket, YEBuiltin, YECall, YStatement, YSBreak, YSContinue, YSExpression, YSBlock, YSReturn, YSTypedef, YSFunction, YSAssign, YSBracket, YSIf, YSWhile, YSRepeat, YSDo, YSTextdomain, YSInclude, YSImport, YSFilename, and YSSwitch.
References kind(), toString(), and y2debug.
| bool YCode::isConstant | ( | ) | const [virtual] |
| bool YCode::isError | ( | ) | const |
returns true if the YCode represents an error
Referenced by evaluate().
| bool YCode::isStatement | ( | ) | const [virtual] |
returns true if the YCode represents a statement
Reimplemented in YBlock, and YStatement.
| bool YCode::isBlock | ( | ) | const [virtual] |
returns true if the YCode represents a block
Reimplemented in YBlock.
Referenced by YECall::finalize().
| bool YCode::isReferenceable | ( | ) | const [virtual] |
returns true if the YCode represents something we can reference to
Reimplemented in YEVariable.
| YCPValue YCode::evaluate | ( | bool | cse = false |
) | [virtual] |
evaluate YCode to YCPValue if debugger == 0 called for parse time evaluation (i.e. constant subexpression elimination) else called for runtime evaluation
Reimplemented in YBlock, YConst, YLocale, YFunction, YEVariable, YEReference, YETerm, YECompare, YELocale, YEList, YEMap, YEPropagate, YEUnary, YEBinary, YETriple, YEIs, YEReturn, YEBracket, YEBuiltin, YEFunction, YEFunctionPointer, YStatement, YSBreak, YSContinue, YSExpression, YSBlock, YSReturn, YSTypedef, YSFunction, YSAssign, YSBracket, YSIf, YSWhile, YSRepeat, YSDo, YSTextdomain, YSInclude, YSImport, YSFilename, and YSSwitch.
References isError(), toString(), y2debug, and y2error.
| constTypePtr YCode::type | ( | ) | const [virtual] |
return type (interesting mostly for function calls)
Reimplemented in YBlock, YConst, YLocale, YFunction, YEVariable, YEReference, YETerm, YECompare, YELocale, YEList, YEMap, YEPropagate, YEUnary, YEBinary, YETriple, YEIs, YEReturn, YEBracket, YEBuiltin, YECall, YStatement, YSExpression, YSBlock, YSReturn, YSTypedef, YSFunction, YSBracket, YSIf, YSWhile, YSRepeat, YSDo, YSTextdomain, YSInclude, YSImport, YSFilename, and YSSwitch.
References Type::Unspec.
1.5.5