=================================================================== RCS file: /home/cvs/OpenXM/src/k097/slib.sm1,v retrieving revision 1.8 retrieving revision 1.10 diff -u -p -r1.8 -r1.10 --- OpenXM/src/k097/slib.sm1 2001/01/08 05:26:49 1.8 +++ OpenXM/src/k097/slib.sm1 2003/11/20 09:20:36 1.10 @@ -470,6 +470,13 @@ FunctionValue } def this [ %% function args Arglist ] {Length} sendmsg2 /argsize set +this [ %% function args +vList ] {IsArray} sendmsg2 + %% if-condition + { %%ifbody + vList {toString} map from_records /vList set }%%end if if body + { %%if- else part + } ifelse argsize (1).. eq %% if-condition { %%ifbody @@ -496,9 +503,11 @@ weightMatrix ] {Length} sendmsg2 this [ %% function args size ] {NewVector} sendmsg2 /new0 set - /@@@.indexMode.flag.save @@@.indexMode.flag def 0 @@@.indexMode (0).. %%PSfor initvalue. + /@@@.indexMode.flag.save @@@.indexMode.flag def 0 @@@.indexMode (0).. size 2 -1 roll +%%PSfor initvalue. (integer) data_conversion -size (1).. sub (integer) data_conversion 1 2 -1 roll + 2 -1 roll + (1).. sub (integer) data_conversion 1 2 -1 roll { %% for body (universalNumber) data_conversion /i set weightMatrix [i ] Get @@ -1116,6 +1125,22 @@ FunctionValue } def [/this /a ] /ArgNames set ArgNames pushVariables [ %%function body [Argthis] Arglist join ArgNames mapset a pmat /ExitPoint ]pop popVariables %%pop argValues + db.DebugStack setstack pop stdstack +} def +%%end of function + +/QuoteMode { + db.DebugStack setstack $In function : QuoteMode of class PrimitiveObject$ stdstack + /Arglist set /Argthis set /FunctionValue [ ] def + [/this /a ] /ArgNames set ArgNames pushVariables [ %%function body + [Argthis] Arglist join ArgNames mapset +a (0).. eq + %% if-condition + { %%ifbody + [(QuoteMode) 0] system_variable }%%end if if body + { %%if- else part + [(QuoteMode) 1] system_variable } ifelse +/ExitPoint ]pop popVariables %%pop argValues db.DebugStack setstack pop stdstack } def %%end of function