diff -r 91d6c3973952 -r 90bedd5a9f75 Context.st --- a/Context.st Mon May 12 21:45:10 1997 +0200 +++ b/Context.st Tue May 13 16:35:46 1997 +0200 @@ -11,8 +11,8 @@ " Object variableSubclass:#Context - instanceVariableNames:'flags sender* home receiver selector searchClass lineNr retvalTemp - handle*' + instanceVariableNames:'flags sender* home receiver selector searchClass lineNr + retvalTemp handle*' classVariableNames:'InvalidReturnSignal SingleStepInterruptRequest' poolDictionaries:'' category:'Kernel-Methods' @@ -1312,17 +1312,15 @@ canReturn "return true, if the receiver allows returning through it. - For normal method contexts, this returns true; - for blocks, it (currently) always returns false. - - However, the system can be compiled (for production code), to create - contexts which cannot be returned or restarted - (except, if the method contains a returning block). - This saves some administrative work in every method - invocation and makes overall execution faster. However, it limits - the debugger, in that it cannot return from or restart those contexts. - (unwinding and termination is not affected by this optimization) - Currently, the system as delivered has this optimization disabled." + Blocks, it (currently) always returns false. + Methods which contain a (non-inlined) block are always + returnable - for other methods, it depends on how the system + was compiled (stc flag +/-optContext). + If it was compiled with +optContext, methods are compiled + non returnable. + Since this saves some administrative work in every method + invocation and makes overall execution faster, the system classes + are all compiled with this flag turned on." %{ /* NOCONTEXT */ @@ -1331,13 +1329,23 @@ ! hasStackToShow + "private interface to the debugger. + Smalltalk contexts return false here - other language frames + (i.e. Java frames) may want to show the evaluation stack" + ^ false "Created: 28.6.1996 / 14:48:39 / cg" + "Modified: 13.5.1997 / 16:31:12 / cg" ! isNonLifo - "return true, if this is a nonLifo context" + "return true, if this is a nonLifo context. + A nonLifo context is one that is still on the machine stack, + but has a reference taken and needs to be converted to a real + object (in objectMemory) when the method/block returns. + You dont have to understand this - this is a special ST/X + debug query, which may be removed without notice." %{ /* NOCONTEXT */ RETURN ( ((INT)__INST(flags) & __MASKSMALLINT(__NONLIFO)) ? true : false ); @@ -1346,7 +1354,9 @@ isOnMachineStack "return true, if this is a machine stack context as opposed to a - real heap context" + real heap context. + You dont have to understand this - this is a special ST/X + debug query, which may be removed without notice." %{ /* NOCONTEXT */ RETURN ( (__qSpace(self) >= STACKSPACE) ? true : false ); @@ -1429,6 +1439,6 @@ !Context class methodsFor:'documentation'! version - ^ '$Header: /cvs/stx/stx/libbasic/Context.st,v 1.78 1997-03-27 15:48:47 cg Exp $' + ^ '$Header: /cvs/stx/stx/libbasic/Context.st,v 1.79 1997-05-13 14:35:46 cg Exp $' ! ! Context initialize!