81 #include "SystemInterpreter.hpp"
89 #include "SysFileSystem.hpp"
102 #define line_delimiters "\r\n"
190 const char *_current;
205 if (start[0] ==
'#' && start[1] ==
'!')
207 memcpy(start,
"--", 2);
213 indices->
copyData(&descriptor,
sizeof(descriptor));
216 scan = (
const char *)memchr(start,
ctrl_z, length);
219 length = scan - start;
226 descriptor.
position = _current - start;
230 while (scan !=
OREF_NULL && *scan ==
'\0')
237 _current = _current + length;
238 descriptor.
length = length;
244 descriptor.
length = scan - _current;
250 if (length > (
size_t)(scan - _current))
263 length -= scan - _current;
267 indices->
copyData(&descriptor,
sizeof(descriptor));
294 memcpy(begin,program_source->
getData(), 9);
297 begin[9]=end[3]=0x00;
300 memcpy(program_source->
getData(),
" ", 9);
526 const char *buffer_start;
822 const char *buffer_start;
826 return OREF_NULLSTRING;
851 return new_string(buffer_start + descriptors[_position].
position, descriptors[_position].length);
855 return OREF_NULLSTRING;
860 #define dumpClause(from, source, clause) dumpClauseImpl(from, source, clause)
862 #define dumpClause(from, source, clause)
884 dbgprintf(
"(Parsing)-------------------------------------------------\n");
892 #define dumpTokens(from, source, clause) dumpTokensImpl(from, source, clause)
894 #define dumpTokens(from, source, clause)
905 for (
size_t i=1; i < clause->
free; i++)
914 "(Parsing)startLine=%i startCol=%i endLine=%i endCol=%i "
915 "classId=%s subclass=%s numeric=%i "
925 dbgprintf(
"(Parsing)startLine=%i startCol=%i endLine=%i endCol=%i "
926 "classId=%s subclass=%s numeric=%i "
975 location = token_location;
991 location.
setEnd(token_location);
995 this->
flags &= ~reclaimed;
1006 #define TRACE_OVERHEAD 16
1010 #define INSTRUCTION_OVERHEAD 11
1011 #define LINENUMBER 6
1012 #define PREFIX_OFFSET (LINENUMBER + 1)
1013 #define PREFIX_LENGTH 3
1014 #define INDENT_SPACING 2
1046 size_t indent,
bool trace)
1052 char linenumber[11];
1055 snprintf(linenumber,
sizeof linenumber,
"%zu", location.
getLineNumber());
1060 if (
line == OREF_NULLSTRING)
1095 outlength = strlen(linenumber);
1096 linepointer = linenumber;
1106 buffer->
put(
LINENUMBER - outlength, linepointer, outlength);
1127 return OREF_NULLSTRING;
1131 line = OREF_NULLSTRING;
1225 source->
put(source_line, 1);
1239 source->
put(source_line, 1);
1257 source->
put(source_line, i);
1343 size_t _line_number,
1352 source->
adjustLine(_line_number, _line_number);
1398 bool result =
false;
1640 return routineObject;
1861 createdClasses->
put(newClass, index++);
1864 for (
size_t j = 1; j < index; j++)
1934 while (!this->
atEnd())
1991 next_install = current_class;
2122 this->active_class->setMetaClass(token->
value);
2134 this->active_class->setPublic();
2161 this->active_class->setSubClass(token->
value);
2179 this->active_class->setMixinClass(token->
value);
2199 this->active_class->addInherits(token->
value);
2209 if (this->active_class->isAbstract())
2215 this->active_class->setAbstract();
2291 this->active_extension->addInherits(token->
value);
2392 bool Attribute =
false;
2393 bool abstractMethod =
false;
2440 if (externalname !=
OREF_NULL || abstractMethod)
2452 externalname = token->
value;
2550 if (abstractMethod || externalname !=
OREF_NULL)
2555 if (externalname !=
OREF_NULL || Attribute)
2559 abstractMethod =
true;
2600 addMethod(internalname, _method, Class);
2619 else if (abstractMethod)
2660 addMethod(internalname, _method, Class);
2868 procedure = methodName;
2874 if (((
RexxString *)(_words->
get(1)))->strCompare(CHAR_LIBRARY))
2877 if (_words->
size() == 3)
2882 else if (_words->
size() == 2)
2899 #define ATTRIBUTE_BOTH 0
2900 #define ATTRIBUTE_GET 1
2901 #define ATTRIBUTE_SET 2
2914 bool abstractMethod =
false;
3053 if (externalname !=
OREF_NULL || abstractMethod)
3065 externalname = token->
value;
3070 if (abstractMethod || externalname !=
OREF_NULL)
3074 abstractMethod =
true;
3116 addMethod(internalname, _method, Class);
3126 else if (abstractMethod)
3156 if (internalname == procedure)
3159 p_procedure = procedure;
3167 addMethod(internalname, _method, Class);
3170 else if (abstractMethod)
3181 createMethod(internalname, Class, Access, Protected, guard,
true);
3207 if (internalname == procedure)
3210 p_procedure = procedure;
3221 else if (abstractMethod)
3232 createMethod(setterName, Class, Access, Protected, guard,
true);
3347 _method->
setAttributes(privateMethod, protectedMethod, guardedMethod);
3376 _method->
setAttributes(privateMethod, protectedMethod, guardedMethod);
3404 _method->
setAttributes(privateMethod, protectedMethod, guardedMethod);
3433 _method->
setAttributes(privateMethod, protectedMethod, guardedMethod);
3530 externalname = token->
value;
3569 if (((
RexxString *)(_words->
get(1)))->strCompare(CHAR_LIBRARY))
3576 if (_words->
size() == 3)
3581 else if (_words->
size() == 2)
3612 else if (((
RexxString *)(_words->
get(1)))->strCompare(CHAR_REGISTERED))
3619 if (_words->
size() == 3)
3624 else if (_words->
size() == 2)
3820 second = this->
popDo();
3834 second = this->
popDo();
3907 this->
pushDo(_instruction);
3956 type = _instruction->
getType();
3989 second = this->
topDo();
4007 if (this->
flags&no_clause)
4028 if (this->
flags&no_clause)
4051 if (this->
flags&no_clause)
4068 second = this->
topDo();
4075 second = this->
popDo();
4076 this->
pushDo(_instruction);
4087 if (this->
flags&no_clause)
4102 second = this->
topDo();
4110 this->
pushDo(_instruction);
4124 second = this->
popDo();
4147 second = this->
popDo();
4165 this->
pushDo(_instruction);
4169 this->
pushDo(_instruction);
4185 if (
isOfClass(FunctionCallTerm, _instruction))
4253 return _instruction;
4320 return _instruction;
4335 return _instruction;
4361 _instruction = this->
nopNew();
4367 _instruction = this->
dropNew();
4379 _instruction = this->
callNew();
4409 _instruction = this->
doNew();
4415 _instruction = this->
loopNew();
4421 _instruction = this->
exitNew();
4478 if (this->
flags&_interpret)
4487 if (this->
flags&_interpret)
4502 if (this->
flags&_interpret)
4511 if (this->
flags&_interpret)
4514 _instruction = this->
useNew();
4538 _instruction = this->
sayNew();
4568 _instruction = this->
elseNew(_first);
4574 _instruction = this->
endNew();
4596 return _instruction;
4684 const char * _position;
4691 end = _position + length;
4695 while (*_position !=
'.')
4700 stemName =
new_string(start, _position - start + 1);
4701 stemRetriever = this->
addStem(stemName);
4713 while (_position < end)
4715 if (*_position ==
'.')
4725 if (!(tail->
getLength() == 0 || (*start >=
'0' && *start <=
'9')))
4736 }
while (_position < end);
4899 PackageClass *
package = this->isInterpret() ? this->interpret_activation->getPackage() : this->getPackage();
4968 "(Parsing)Add RexxInstruction : instructionType=\"%s\" instructionFlags=%i "
4969 "startLine=%i startCol=%i endLine=%i endCol=%i "
4970 "instruction={%s}\n",
4979 dbgprintf(
"(Parsing)Add RexxInstruction : instructionType=\"%s\" instructionFlags=%i "
4980 "startLine=%i startCol=%i endLine=%i endCol=%i "
4981 "instruction={%s}\n",
5083 _expression = this->
addText(token);
5087 _expression = this->
addText(token);
5091 _expression = this->
addText(token);
5137 _expression = this->
addText(token);
5141 _expression = this->
addText(token);
5145 _expression = this->
addText(token);
5298 while (!this->
terminator(terminators, token))
5450 bool namedArgumentAllowed,
5458 size_t namedArgCount=0;
5462 this->
argList(_first, terminators, namedArgumentAllowed, argCount, namedArgCount);
5467 while (argCount > 0)
5473 _namedArgArray =
new_array(2 * namedArgCount);
5476 while (namedArgCount > 0)
5490 bool namedArgumentAllowed,
5491 size_t &positionalArgumentCount,
5492 size_t &namedArgumentCount)
5529 bool namedArgument =
false;
5535 arglist->
push(expr);
5536 positionalArgumentCount = 1;
5537 namedArgumentCount = 0;
5576 arglist->
push(subexpr);
5593 new_string(
"Named argument: expected symbol followed by colon, or colon followed by symbol"));
5602 subexpr = this->
addText(token);
5603 namedArglist->
push(subexpr);
5613 new_string(
"Named argument: expected symbol followed by colon, or colon followed by symbol"));
5623 new_string(
"Named argument: expected symbol followed by colon, or colon followed by symbol"));
5628 namedArglist->
push(subexpr);
5655 this->
popNTerms(total + ((2 * namedTotal)));
5677 arglist->
push(expr);
5684 positionalArgumentCount = total;
5685 namedArgumentCount = namedTotal;
5700 size_t namedArgCount=0;
5709 _function =
new (argCount + (2 * namedArgCount))
RexxExpressionFunction(name->
value, argCount, this->subTerms, namedArgCount, this->namedSubTerms, this->resolveBuiltin(name->
value), name->
isLiteral());
5728 size_t namedArgCount=0;
5751 size_t namedArgCount=0;
5793 size_t namedArgCount;
5795 bool messagenameProvided =
true;
5809 token = this->
getToken(terminators, 0 );
5814 messagename = (
RexxString *)OREF_TILDE_ROUND_BRACKETS;
5815 messagenameProvided =
false;
5820 messagename = token->
value;
5828 token = this->
getToken(terminators, 0);
5844 token = this->
getToken(terminators, 0);
5847 if (!messagenameProvided)
5902 result = this->
addText(_first);
6100 term = this->
function(second, token, terminators);
6272 wordlist->
push(word);
6279 wordlist->
push(word);
6287 wordarray->
put(wordlist->
pop(), count--);
6414 const char *newline = strchr(
string,
'\n');
6415 if (newline) value =
new_string(
string, newline -
string);
6471 switch (_instruction->
getType())
6502 void *RexxSource::operator
new (
size_t size)
6555 for (
size_t _position = 0; _position < length; _position++)
6559 switch (value->
getChar(_position))
6622 badOption = value->
getChar(_position);
6630 newSetting = setting | debug;
6696 retriever = this->
addText(token);
6727 retriever = this->
addText(token);
6766 if (list_count == 0)
6787 int *condition_type,
6858 if (condition_type != NULL)
6860 *condition_type = _keyword;
6881 argList(_first, terminators,
false, count, namedCount);
6929 return packageInstance;
6953 return packageInstance;
void reportException(wholenumber_t error)
RexxArray * new_array(size_t s)
RexxBuffer * new_buffer(size_t s)
RexxDirectory * new_directory()
RexxIdentityTable * new_identity_table()
RexxInteger * new_integer(wholenumber_t v)
#define TheCommonRetrievers
bool isMethod(RexxObject *o)
#define Error_Translation_body_error
#define Error_Invalid_expression_until
#define Error_Translation_external_routine
#define Error_Translation_invalid_line
#define Error_Unexpected_then_else
#define Error_Symbol_or_string_fuzz_value
#define Error_Translation_bad_external
#define Error_Symbol_or_string_external
#define Error_Symbol_or_string_constant_value
#define Message_Translations_no_source_available
#define Error_Symbol_or_string_constant
#define Error_Unmatched_parenthesis_square
#define Error_Translation_constant_body
#define Error_Symbol_expected_colon
#define Error_Translation_attribute_method
#define Error_Translation_reply_interpret
#define Error_Invalid_subkeyword_method
#define Error_Symbol_or_string_trace_value
#define Error_Invalid_subkeyword_requires
#define Error_Invalid_expression_message_term
#define Error_Invalid_variable_period
#define Error_Execution_cyclic
#define Error_Unexpected_end_else
#define Error_Unexpected_comma_paren
#define Error_Unmatched_parenthesis_paren
#define Error_Translation_duplicate_constant
#define Error_Symbol_or_string_mixinclass
#define Error_Unexpected_comma_bracket
#define Error_Invalid_subkeyword_class
#define Error_Invalid_do_whileuntil
#define Error_External_name_not_found_routine
#define Error_Unexpected_end_then
#define Error_Translation_directive_interpret
#define Error_Program_unreadable_name
#define Error_Invalid_trace_trace
#define Error_Invalid_subkeyword_attribute
#define Error_Incomplete_do_otherwise
#define Error_Unexpected_comma_comma
#define Error_Routine_not_found_requires
#define Error_Symbol_or_string_attribute
#define Error_Symbol_or_string_inherit
#define Error_Invalid_expression_after_tilde
#define Error_Invalid_variable_number
#define Error_Symbol_or_string_digits_value
#define Error_Translation_bad_directive
#define Error_Symbol_or_string_routine
#define Error_Symbol_expected_varref
#define Error_Invalid_expression_general
#define Error_Symbol_expected_expose
#define Error_Translation_expose_interpret
#define Error_Translation_forward_interpret
#define Error_Symbol_or_string_subclass
#define Error_Symbol_expected_drop
#define Error_Invalid_subkeyword_options
#define Error_Translation_external_method
#define Error_Invalid_data_constant_dir
#define Error_Invalid_expression_prefix
#define Error_Symbol_expected_upper
#define Error_Translation_duplicate_attribute
#define Error_Translation_abstract_attribute
#define Error_Unexpected_when_when
#define Error_Symbol_or_string_method
#define Error_Symbol_or_string_requires
#define Error_Translation_external_attribute
#define Error_Then_expected_if
#define Error_Unexpected_then_then
#define Error_Variable_reference_missing
#define Error_Symbol_expected_directive
#define Error_Symbol_or_string_class
#define Error_Symbol_or_string_metaclass
#define Error_Expression_result_digits
#define Error_Translation_use_interpret
#define Error_Incomplete_do_then
#define Error_Incomplete_do_else
#define Error_Translation_missing_class
#define Error_When_expected_whenotherwise
#define Error_Invalid_subkeyword_routine
#define Error_Invalid_whole_number_fuzz
#define Error_Translation_invalid_attribute
#define Message_Translations_internal_code
#define Error_Unexpected_end_nodo
#define Error_Translation_user_defined
#define Error_Translation_guard_interpret
#define Error_External_name_not_found_method
#define Error_Unexpected_label_interpret
#define Error_Translation_abstract_method
#define Error_Incomplete_do_do
#define Error_Variable_reference_extra
#define Error_Unexpected_when_otherwise
#define Error_Translation_duplicate_method
#define Error_Invalid_expression_while
#define Error_Incomplete_do_loop
#define Error_Translation_duplicate_routine
#define Error_Invalid_whole_number_digits
#define Error_Translation_duplicate_class
#define Error_Translation_expose
#define Error_Invalid_subkeyword_form
#define Error_Incomplete_do_select
#define FIRST_VARIABLE_INDEX
#define memory_mark(oref)
RexxObject * new_object(size_t s)
#define flatten_reference(oref, envel)
#define memory_mark_general(oref)
#define setUpFlatten(type)
#define dumpClause(from, source, clause)
#define dumpTokens(from, source, clause)
void dumpTokensImpl(const char *from, RexxSource *source, RexxClause *clause)
#define INSTRUCTION_OVERHEAD
struct _LINE_DESCRIPTOR LINE_DESCRIPTOR
void dumpClauseImpl(const char *from, RexxSource *source, RexxClause *clause)
RexxString * raw_string(stringsize_t l)
RexxString * new_string(const char *s, stringsize_t l)
#define STRING_COMPOUND_NAME
#define SUBDIRECTIVE_NOCOMMANDS
#define SUBDIRECTIVE_EXTERNAL
#define KEYWORD_OTHERWISE
#define SUBDIRECTIVE_LIBRARY
#define SUBKEY_SCIENTIFIC
#define SUBDIRECTIVE_MIXINCLASS
#define OPERATOR_SUBTRACT
#define SUBDIRECTIVE_PACKAGE
#define SUBDIRECTIVE_FORM
#define OPERATOR_BACKSLASH
#define SUBDIRECTIVE_COMMANDS
#define DIRECTIVE_EXTENSION
#define SUBDIRECTIVE_MACROSPACE
#define DIRECTIVE_REQUIRES
#define SUBDIRECTIVE_GUARDED
#define DIRECTIVE_ROUTINE
#define KEYWORD_PROCEDURE
#define SUBDIRECTIVE_UNGUARDED
#define SUBDIRECTIVE_INHERIT
#define SUBDIRECTIVE_SUBCLASS
#define SUBDIRECTIVE_ATTRIBUTE
#define refineSubclass(token, refinedSubclass)
#define SUBKEY_ENGINEERING
#define SUBDIRECTIVE_UNPROTECTED
#define OPERATOR_STRICT_EQUAL
#define SUBDIRECTIVE_TRACE
#define SUBDIRECTIVE_FUZZ
#define SUBDIRECTIVE_DIGITS
#define SUBDIRECTIVE_NOMACROSPACE
#define DIRECTIVE_ATTRIBUTE
#define SUBDIRECTIVE_ABSTRACT
#define DIRECTIVE_OPTIONS
#define SUBDIRECTIVE_CLASS
#define SUBDIRECTIVE_PRIVATE
#define KEYWORD_INTERPRET
#define SUBDIRECTIVE_PUBLIC
#define SUBDIRECTIVE_METACLASS
#define DIRECTIVE_CONSTANT
#define SUBDIRECTIVE_PROTECTED
#define TOKEN_SOURCE_LITERAL
#define CONCURRENCY_TRACE
static RexxObject * getLocalEnvironment(RexxString *name)
static RexxActivity *volatile currentActivity
BaseExecutable * setSourceObject(RexxSource *s)
RexxString * getMetaClass()
void removeDependency(RexxString *name)
bool checkDuplicateMethod(RexxString *name, bool classMethod)
RexxClass * install(RexxSource *source, RexxActivation *activation)
RexxString * getSubClass()
void addConstantMethod(RexxString *name, RexxMethod *method)
void addMethod(RexxString *name, RexxMethod *method, bool classMethod)
bool dependenciesResolved()
void addDependencies(RexxDirectory *class_directives)
void addMethod(RexxString *name, RexxMethod *method, bool classMethod)
bool checkDuplicateMethod(RexxString *name, bool classMethod)
void addConstantMethod(RexxString *name, RexxMethod *method)
void install(RexxSource *source, RexxActivation *activation)
PackageClass * loadRequires(RexxActivity *activity, RexxString *shortName, const char *data, size_t length)
RexxString * resolveProgramName(RexxString *name, RexxString *dir, RexxString *ext)
void install(RexxActivation *context)
static const bool DEFAULT_FORM
static const bool FORM_SCIENTIFIC
static const size_t DEFAULT_FUZZ
static const bool FORM_ENGINEERING
static const size_t DEFAULT_DIGITS
RexxSource * getSourceObject()
static RoutineClass * resolveRoutine(RexxString *function, RexxString *packageName, RexxString *procedure)
static RexxNativeMethod * resolveMethod(RexxString *packageName, RexxString *methodName)
void install(RexxActivation *context)
RexxString * formatSourcelessTraceLine(RexxString *packageName)
static const bool default_enable_macrospace
static size_t processTraceSetting(size_t traceSetting)
static const size_t default_trace_flags
static const bool default_enable_commands
void raiseException(wholenumber_t, RexxString *, RexxArray *, RexxObject *)
RexxString * buildMessage(wholenumber_t, RexxArray *)
InterpreterInstance * getInstance()
void put(RexxObject *eref, size_t pos)
RexxObject * get(size_t pos)
void setStart(size_t, size_t)
void setEnd(size_t, size_t)
SourceLocation clauseLocation
const SourceLocation & getLocation()
void setLocation(SourceLocation &l)
RexxObject * setEntry(RexxString *, RexxObject *)
RexxObject * put(RexxObject *, RexxString *)
RexxObject * fastAt(RexxString *name)
RexxObject * entry(RexxString *)
bool available(HashLink pos)
RexxObject * value(HashLink pos)
HashLink next(HashLink pos)
RexxObject * index(HashLink pos)
virtual RexxObject * put(RexxObject *, RexxObject *)
virtual RexxObject * remove(RexxObject *key)
SourceLocation instructionLocation
const SourceLocation & getLocation()
void setNext(RexxInstruction *next)
uint16_t instructionFlags
RexxInstruction * nextInstruction
void setBehaviour(RexxBehaviour *b)
RexxObject * removeIndex(size_t i)
RexxObject * append(RexxObject *)
size_t nextIndex(size_t i)
RexxObject * hasItem(RexxObject *)
RexxObject * removeFirst()
RexxObject * getValue(size_t i)
void setAttributes(AccessFlag access, ProtectedFlag _protected, GuardFlag _guarded)
virtual BaseCode * setSourceObject(RexxSource *s)
RexxNumberString * numberString()
bool requestUnsignedNumber(stringsize_t &, size_t)
RexxInteger * requestInteger(size_t)
void sendMessage(RexxString *, RexxArray *, RexxDirectory *, ProtectedObject &)
void push(RexxObject *obj)
void queue(RexxObject *obj)
size_t copyData(void *, size_t)
RexxInstruction * loopNew()
RexxStemVariable * addStem(RexxString *)
RexxDirectory * class_dependencies
void resetPosition(size_t p)
RexxObject * subExpression(int)
static const size_t TRACE_COMMANDS
void pushDo(RexxInstruction *i)
void createConstantGetterMethod(RexxString *name, RexxObject *value)
PackageClass * loadRequires(RexxActivity *activity, RexxString *target)
static const size_t TRACE_ERRORS
RexxToken * sourceNextToken(RexxToken *)
RexxList * sourceLiterals
RexxToken * popOperator()
static int subDirective(RexxToken *)
RexxInstruction * labelNew()
void decodeExternalMethod(RexxString *methodName, RexxString *externalSpec, RexxString *&library, RexxString *&procedure)
static int keyDirective(RexxToken *)
RexxDirectory * public_routines
RexxObject * parseLogical(RexxToken *first, int terminators)
RexxCode * translateBlock(RexxDirectory *)
RexxInstruction * forwardNew()
static const size_t TRACE_INTERMEDIATES
void createAttributeGetterMethod(RexxString *name, RexxVariableBase *retriever, bool classMethod, AccessFlag privateMethod, ProtectedFlag protectedMethod, GuardFlag guardedMethod)
RexxInstruction * traceNew()
static const size_t TRACE_SETTING_MASK
RexxObject * collectionMessage(RexxToken *, RexxObject *, int)
void extensionDirective()
RexxInstruction * ifNew(int)
RexxString * programDirectory
void addClause(RexxInstruction *)
static int precedence(RexxToken *)
RexxString * programExtension
void argList(RexxToken *, int, bool, size_t &, size_t &)
RexxCode * interpret(RexxString *, RexxDirectory *, size_t, RexxActivation *)
RexxMethod * createNativeMethod(RexxString *name, RexxString *library, RexxString *procedure)
void resolveDependencies()
RexxObject * expression(int)
RexxInstruction * messageAssignmentNew(RexxExpressionMessage *, RexxObject *)
void checkDuplicateMethod(RexxString *name, bool classMethod, int errorMsg)
void extractNameInformation()
RexxInstruction * exitNew()
RexxString * traceBack(RexxActivation *, SourceLocation &, size_t, bool)
RexxInstruction * findLabel(RexxString *)
RexxInstruction * topDo()
RexxInstruction * exposeNew()
void flatten(RexxEnvelope *)
RexxSource * parentSource
RexxInstruction * instruction()
static int subKeyword(RexxToken *)
RexxObject * fullSubExpression(int)
void createAbstractMethod(RexxString *name, bool classMethod, AccessFlag privateMethod, ProtectedFlag protectedMethod, GuardFlag guardedMethod, bool isAttribute)
void syntaxError(int errorcode, RexxInstruction *i)
RexxObject * popNTerms(size_t)
RexxString * resolveProgramName(RexxActivity *activity, RexxString *name)
RoutineClass * findPublicRoutine(RexxString *)
RexxInstruction * elseNew(RexxToken *)
RexxInstruction * raiseNew()
RexxObject * messageSubterm(int)
SourceLocation clauseLocation
RexxInstruction * assignmentNew(RexxToken *)
RexxArray * extractSource()
RexxToken * getToken(int, int)
RexxObject * messageTerm()
RexxObject * subTerm(int)
static const size_t TRACE_LABELS
RexxInstruction * messageAssignmentOpNew(RexxExpressionMessage *, RexxToken *, RexxObject *)
void addLabel(RexxInstruction *, RexxString *)
RexxVariableBase * getRetriever(RexxString *)
ExtensionDirective * active_extension
void pushOperator(RexxToken *operatorToken)
RexxObject * functionCallMessage(RexxToken *, RexxObject *, int)
void libraryDirective(RexxString *name, RexxToken *token)
ClassDirective * active_class
RexxObject * toss(RexxObject *)
void syntaxErrorAt(int errorcode, RexxToken *token)
void errorLine(int, RexxInstruction *)
RexxInstruction * signalNew()
RexxObject * parseConditional(int *, int)
RexxInstruction * leaveNew(int)
RexxActivation * interpret_activation
RexxInstruction * addressNew()
RexxCompoundVariable * addCompound(RexxString *)
RexxInstruction * numericNew()
void addReference(RexxObject *reference)
SecurityManager * securityManager
void createAttributeSetterMethod(RexxString *name, RexxVariableBase *retriever, bool classMethod, AccessFlag privateMethod, ProtectedFlag protectedMethod, GuardFlag guardedMethod)
RexxInstruction * upperNew()
StackFrameClass * createStackFrame()
void pushSubTerm(RexxObject *)
RexxCode * translate(RexxDirectory *)
RexxInstruction * endNew()
RexxCode * generateCode(bool isMethod)
void addInstalledRoutine(RexxString *name, RoutineClass *routineObject, bool publicRoutine)
RexxObject * constantLogicalExpression()
static const size_t DEBUG_ON
void removeObj(RexxObject *object)
RexxList * loadedPackages
RexxInstruction * parseNew(int)
void blockSyntaxError(RexxInstruction *i)
void errorToken(int, RexxToken *)
void argArray(RexxToken *, int, bool, RexxArray *&, RexxArray *&)
static RexxString * formatTraceSetting(size_t source)
RexxInstruction * useNew()
RexxInstruction * thenNew(RexxToken *, RexxInstructionIf *)
RexxCode * interpretMethod(RexxDirectory *, RexxActivation *)
RexxToken * topOperator()
void liveGeneral(int reason)
RexxInstruction * returnNew()
RoutineClass * findRoutine(RexxString *)
RexxInstruction * dropNew()
static const size_t TRACE_IGNORE
void position(size_t, size_t)
static const size_t DEBUG_OFF
void blockError(RexxInstruction *)
RexxInstruction * optionsNew()
void adjustLine(size_t, size_t)
void expose(RexxString *)
RexxInstruction * messageNew(RexxExpressionMessage *)
RexxInstruction * replyNew()
void createMethod(RexxString *name, bool classMethod, AccessFlag privateMethod, ProtectedFlag protectedMethod, GuardFlag guardedMethod, bool isAttribute)
RexxString * commonString(RexxString *)
RexxInstruction * popDo()
RexxSource(RexxString *, RexxArray *)
void addInstalledClass(RexxString *name, RexxClass *classObject, bool publicClass)
RexxInstruction * interpretNew()
RexxInstruction * sourceNewObject(size_t, RexxBehaviour *, int)
RexxString * extract(SourceLocation &, bool=false)
size_t processVariableList(int)
RexxClass * findPublicClass(RexxString *name)
RexxObject * constantExpression()
RexxInstruction * doNew()
PackageClass * getPackage()
void errorPosition(int, SourceLocation)
RexxDirectory * variables
RexxInstruction * commandNew()
void pushTerm(RexxObject *)
static const size_t TRACE_NORMAL
RexxInstruction * nopNew()
void holdObject(RexxObject *object)
void addMethod(RexxString *name, RexxMethod *method, bool classMethod)
RexxObject * message(RexxObject *, bool, int)
RexxObject * variableOrMessageTerm()
void mergeRequired(RexxSource *)
RexxDirectory * installed_classes
void initBuffered(RexxBuffer *)
RexxInstruction * queueNew(int)
RexxInstruction * sayNew()
void setProgramName(RexxString *name)
RexxInstruction * assignmentOpNew(RexxToken *, RexxToken *)
RexxObject * popSubTerm()
void saveObject(RexxObject *object)
RexxVariableBase * addVariable(RexxString *)
static const size_t TRACE_RESULTS
void needVariableOrDotSymbol(RexxToken *)
RexxIdentityTable * guard_variables
RexxDirectory * installed_public_classes
void checkDirective(int errorCode)
void processInstall(RexxActivation *)
RexxIdentityTable * savelist
void inheritSourceContext(RexxSource *source)
RexxInstruction * otherwiseNew(RexxToken *)
RexxInstruction * currentInstruction
RexxClass * findInstalledClass(RexxString *name)
void flushControl(RexxInstruction *)
RexxObject * function(RexxToken *, RexxToken *, int)
RexxDirectory * merged_public_classes
static const size_t TRACE_OFF
RexxBuffer * sourceBuffer
RexxDirectory * merged_public_routines
RexxDirectory * exposed_variables
RexxInstruction * guardNew()
RexxInstruction * endIfNew(RexxInstructionIf *)
RexxObject * parenExpression(RexxToken *)
void attributeDirective()
RexxQueue * namedSubTerms
RexxArray * words(RexxString *)
RexxClass * findClass(RexxString *)
static const size_t DEBUG_IGNORE
void needVariable(RexxToken *)
RexxObject * addText(RexxToken *)
bool terminator(int, RexxObject *)
static const size_t TRACE_ALL
static bool parseTraceSetting(RexxString *, size_t &, size_t &, char &)
void addPackage(PackageClass *package)
static const size_t DEFAULT_TRACE_SETTING
static const size_t DEBUG_TOGGLE
RoutineClass * findLocalRoutine(RexxString *)
RexxInstruction * procedureNew()
static const size_t TRACE_FAILURES
RexxInstruction * selectNew()
RexxInstruction * callNew()
RexxBuffer * sourceIndices
RexxString * stringValue()
RexxObject * getEncoding()
const char * getStringData()
void setNumberString(RexxObject *)
void set(size_t s, int c, size_t l)
RexxString * extract(size_t offset, size_t sublength)
RexxString * word(RexxInteger *)
RexxString * concatWithCstring(const char *)
RexxString * concat(RexxString *)
RexxString * concatToCstring(const char *)
void put(size_t s, const void *b, size_t l)
SourceLocation tokenLocation
static const char * keywordText(int code)
static const char * codeText(int code)
const SourceLocation & getLocation()
bool isType(TokenClass t)
static RexxObject * buildCompoundVariable(RexxString *variable_name, bool direct)
void call(RexxActivity *, RexxString *, RexxObject **, size_t, size_t, RexxString *, RexxString *, int, ProtectedObject &)
RexxObject * checkEnvironmentAccess(RexxString *index)
RexxObject * checkLocalAccess(RexxString *index)
size_t getEndLine() const
size_t getLineNumber() const
void setEnd(SourceLocation &l)
size_t getEndOffset() const
void setEndLine(size_t l)
void setLineNumber(size_t l)
bool isLimitedTrace() const
void setLimitedTrace(bool b)
void setEndOffset(size_t l)
static RexxString * extractFile(RexxString *file)
static RexxString * extractDirectory(RexxString *file)
static RexxString * extractExtension(RexxString *file)
static RexxBuffer * readProgram(const char *file_name)
static const char * locateCharacter(const char *s, const char *set, size_t l)
static void GetConcurrencyInfos(struct ConcurrencyInfos &concurrencyInfos)
static bool traceConcurrency()
static bool traceParsing()
static int strCaselessCompare(const char *opt1, const char *opt2)
RexxVariableDictionary * variableDictionary
RexxActivation * activation
unsigned short reserveCount
void dbgprintf(const char *format,...)