• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Aucun tag

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

シェルスクリプト言語xyzshのソースコード。


Commit MetaInfo

Révision956cbb8d0e73207f2bf48d7c410c14cab7a92c10 (tree)
l'heure2013-01-06 00:10:33
Auteurab25cq <ab25cq@gmai...>
Commiterab25cq

Message de Log

1.2.9

Change Summary

Modification

--- a/CHANGELOG
+++ b/CHANGELOG
@@ -1,4 +1,28 @@
11
2+2013 1月6日 version 1.2.9
3+
4+ 1. defとclassに-copy-stackframeオプションがつきました。xyzsh.xyzshで定義されているtimes関数で使われてます。
5+
6+ 今までは
7+
8+ > ls | var -local a b c; times 3 ( a )
9+ run time error
10+ not found variable(a)
11+
12+ とtimesのブロック内から外のローカル変数にアクセスできませんでしたが
13+
14+ これからは
15+
16+ > ls | var -local a b c ; times 3 ( a )
17+ bin
18+ bin
19+ bin
20+
21+ のようにブロックの外のローカル変数にアクセスできます。
22+ times内で定義したローカル変数はtimesのブロックの外に出ると消えます。
23+
24+ 2. ダイナミックライブラリーのバージョンアップ
25+
226 2013 4th January version 1.2.8
327
428 1. Refactoring.
--- a/TODO
+++ b/TODO
@@ -2,9 +2,16 @@ Fedoraなど各環境でコンパイルと日本語を通したselectorのチェ
22
33 端末のサイズを変えたときに画面が乱れる mfiler4
44
5-Detected!! at file: src/block.c line:919 function:expand_env_to_command() addr:7f95128197d0
6- Detected!! at file: src/block.c line:919 function:expand_env_to_command() addr:7f951292dbb0
5+block -runがrun_functionになっているのはおかしい
76
7+引数のブロックを格納する変数 BLOCKS
88
9- Detected!! at file: src/block.c line:919 function:expand_env_to_command() addr:7ff502820bb0
10- Detected!! at file: src/block.c line:919 function:expand_env_to_command() addr:7ff502806d50
9+ヘルプの整理
10+
11+xyzshのソースの整理
12+
13+ASSERTマクロをもっと使う
14+
15+エラー出力のリダイレクト %2>
16+
17+変数に新規オブジェクトの作成機能はあるが代入の機能がない。
--- a/configure
+++ b/configure
@@ -3024,7 +3024,7 @@ fi
30243024 #####################################################################
30253025 # check operating systems
30263026 #####################################################################
3027-SO_VERSION=1.5.5
3027+SO_VERSION=1.5.8
30283028
30293029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Operating System" >&5
30303030 $as_echo_n "checking Operating System... " >&6; }
--- a/configure.in
+++ b/configure.in
@@ -32,7 +32,7 @@ AC_SUBST(SYSTEM_MIGEMODIR)
3232 #####################################################################
3333 # check operating systems
3434 #####################################################################
35-SO_VERSION=1.5.6
35+SO_VERSION=1.5.8
3636 AC_SUBST(SO_VERSION)
3737 AC_MSG_CHECKING(Operating System)
3838
--- a/help.xyzsh
+++ b/help.xyzsh
@@ -542,6 +542,22 @@ def 関数名(ブロック)
542542 aaa
543543 -def
544544 bbb
545+-copy-stackframe スタックフレーム(ローカル変数の入れ物)を新しく作る際に現在のスタックフレームの内容をコピーします。
546+(例)
547+> vim a.xyzsh
548+def times -copy-stackframe (
549+ print 0 | var -local _i
550+ while(_i | -lt $ARGV[0]) (
551+ | eval $(block)
552+ ++ _i
553+ )
554+)
555+> load a.xyzsh; print Hello | var -local a; times 3 ( a )
556+Hello
557+Hello
558+Hello
559+
560+このオプションがないとtimes 3 ( a ) でaが見つからないエラーが出る。
545561 -
546562 class クラス名(ブロック)
547563 -
@@ -555,6 +571,22 @@ class クラス名(ブロック)
555571 aaa
556572 -def
557573 bbb
574+-copy-stackframe スタックフレーム(ローカル変数の入れ物)を新しく作る際に現在のスタックフレームの内容をコピーします。
575+(例)
576+> vim a.xyzsh
577+class times -copy-stackframe (
578+ print 0 | var -local _i
579+ while(_i | -lt $ARGV[0]) (
580+ | eval $(block)
581+ ++ _i
582+ )
583+)
584+> load a.xyzsh; print Hello | var -local a; times 3 ( a )
585+Hello
586+Hello
587+Hello
588+
589+このオプションがないとtimes 3 ( a ) でaが見つからないエラーが出る。
558590 -
559591 inherit 引数|オプション|ブロック
560592 -
@@ -1410,6 +1442,22 @@ If you omit the block, output the function source.
14101442 aaa
14111443 -def
14121444 bbb
1445+-copy-stackframe When making new stackframe, xyzsh copys variables in old stackframe to new one.
1446+(ex)
1447+> vim a.xyzsh
1448+class times -copy-stackframe (
1449+ print 0 | var -local _i
1450+ while(_i | -lt $ARGV[0]) (
1451+ | eval $(block)
1452+ ++ _i
1453+ )
1454+)
1455+> load a.xyzsh; print Hello | var -local a; times 3 ( a )
1456+Hello
1457+Hello
1458+Hello
1459+
1460+If there is not -copy-stackframe option, xyzsh raises an error which is "not found a variable" on "times 3 ( a )" code.
14131461 -
14141462 class (class name) (block)
14151463 -
--- a/src/block.c
+++ b/src/block.c
@@ -750,9 +750,9 @@ void block_delete_stack(sObject* self)
750750 if(SBLOCK(self).mSource) FREE(SBLOCK(self).mSource);
751751 }
752752
753-//////////////////////////////////////////////////////////////////////////
753+////////////////////////////////////////////////////
754754 // some functions
755-/////////////////////////////////////////////////////////////////////////
755+////////////////////////////////////////////////////
756756 void block_view(sObject* self)
757757 {
758758 printf("mStatmentsNum %d\n", SBLOCK(self).mStatmentsNum);
--- a/src/class.c
+++ b/src/class.c
@@ -13,7 +13,7 @@ static int options_hash_fun(char* key)
1313 return value % XYZSH_OPTION_MAX;
1414 }
1515
16-sObject* class_new_from_gc(sObject* parent, BOOL user_object)
16+sObject* class_new_from_gc(sObject* parent, BOOL user_object, BOOL no_stackframe)
1717 {
1818 sObject* self = gc_get_free_object(T_CLASS, user_object);
1919
@@ -26,11 +26,13 @@ sObject* class_new_from_gc(sObject* parent, BOOL user_object)
2626 SCLASS(self).mOptions = MALLOC(sizeof(option_hash_it)*XYZSH_OPTION_MAX);
2727 memset(SCLASS(self).mOptions, 0, sizeof(option_hash_it)*XYZSH_OPTION_MAX);
2828
29+ SCLASS(self).mFlags = no_stackframe ? FUN_FLAGS_NO_STACKFRAME : 0;
30+
2931 return self;
3032 }
3133
3234
33-sObject* class_clone_from_stack_block_gc(sObject* block, BOOL user_object, sObject* parent)
35+sObject* class_clone_from_stack_block_to_gc(sObject* block, BOOL user_object, sObject* parent, BOOL no_stackframe)
3436 {
3537 sObject* self = gc_get_free_object(T_CLASS, user_object);
3638
@@ -42,11 +44,12 @@ sObject* class_clone_from_stack_block_gc(sObject* block, BOOL user_object, sObje
4244 SCLASS(self).mArgBlocks = NULL;
4345 SCLASS(self).mOptions = MALLOC(sizeof(option_hash_it)*XYZSH_OPTION_MAX);
4446 memset(SCLASS(self).mOptions, 0, sizeof(option_hash_it)*XYZSH_OPTION_MAX);
47+ SCLASS(self).mFlags = no_stackframe ? FUN_FLAGS_NO_STACKFRAME : 0;
4548
4649 return self;
4750 }
4851
49-sObject* class_clone_from_stack_block_stack(sObject* block, sObject* parent)
52+sObject* class_clone_from_stack_block_to_stack(sObject* block, sObject* parent, BOOL no_stackframe)
5053 {
5154 sObject* self = stack_get_free_object(T_CLASS);
5255
@@ -59,6 +62,8 @@ sObject* class_clone_from_stack_block_stack(sObject* block, sObject* parent)
5962 SCLASS(self).mOptions = MALLOC(sizeof(option_hash_it)*XYZSH_OPTION_MAX);
6063 memset(SCLASS(self).mOptions, 0, sizeof(option_hash_it)*XYZSH_OPTION_MAX);
6164
65+ SCLASS(self).mFlags = no_stackframe ? FUN_FLAGS_NO_STACKFRAME : 0;
66+
6267 return self;
6368 }
6469
--- a/src/cmd_base.c
+++ b/src/cmd_base.c
@@ -352,7 +352,6 @@ BOOL cmd_raise(sObject* nextin, sObject* nextout, sRunInfo* runinfo)
352352 return TRUE;
353353 }
354354
355-
356355 BOOL cmd_sweep(sObject* nextin, sObject* nextout, sRunInfo* runinfo)
357356 {
358357 sCommand* command = runinfo->mCommand;
@@ -853,13 +852,15 @@ BOOL cmd_block(sObject* nextin, sObject* nextout, sRunInfo* runinfo)
853852
854853 if(SFUN(fun).mArgBlocks && block_num < vector_count(SFUN(fun).mArgBlocks)) {
855854 sObject* block = vector_item(SFUN(fun).mArgBlocks, block_num);
856- sObject* fun = fun_clone_from_stack_block_stack(block, NULL);
857855
858- if(!run_function(fun, nextin, nextout, runinfo, command->mArgsRuntime + 2, command->mArgsNumRuntime -2, command->mBlocks, command->mBlocksNum))
856+ int rcode = 0;
857+ if(!run(block, nextin, nextout, &rcode, runinfo->mCurrentObject, runinfo->mRunningObject))
859858 {
859+ sCommand* command = runinfo->mCommand;
860+ err_msg_adding("run time error", runinfo->mSName, runinfo->mSLine, command->mArgs[0]);
861+ runinfo->mRCode = rcode;
860862 return FALSE;
861863 }
862- //runinfo->mRCode = runinfo->mRCode;
863864 }
864865 }
865866 else {
--- a/src/cmd_obj.c
+++ b/src/cmd_obj.c
@@ -58,10 +58,12 @@ static BOOL entry_fun(sObject* nextin, sObject* nextout, sRunInfo* runinfo, sObj
5858 sObject* object = runinfo->mCurrentObject;
5959 sCommand* command = runinfo->mCommand;
6060
61+ BOOL no_stackframe = sCommand_option_item(command, "-copy-stackframe");
62+
6163 if(type == T_CLASS)
62- block = class_clone_from_stack_block_gc(block, TRUE, NULL); // block is a stack object, so change the memory manager from stack to gc
64+ block = class_clone_from_stack_block_to_gc(block, TRUE, NULL, no_stackframe); // block is a stack object, so change the memory manager from stack to gc
6365 else
64- block = fun_clone_from_stack_block_gc(block, TRUE, NULL); // block is a stack object, so change the memory manager from stack to gc
66+ block = fun_clone_from_stack_block_to_gc(block, TRUE, NULL, no_stackframe); // block is a stack object, so change the memory manager from stack to gc
6567
6668 if(sCommand_option_item(command, "-inherit")) {
6769 sObject* parent = uobject_item(object, command->mArgsRuntime[1]);
@@ -1209,7 +1211,7 @@ BOOL cmd_mrun(sObject* nextin, sObject* nextout, sRunInfo* runinfo)
12091211 sCommand* command = runinfo->mCommand;
12101212
12111213 if(command->mBlocksNum == 1) {
1212- sObject* klass = class_clone_from_stack_block_stack(command->mBlocks[0], NULL);
1214+ sObject* klass = class_clone_from_stack_block_to_stack(command->mBlocks[0], NULL, sCommand_option_item(command, "-copy-stackframe"));
12131215
12141216 int rcode = 0;
12151217 if(!run(SCLASS(klass).mBlock, nextin, nextout, &rcode, runinfo->mRecieverObject, runinfo->mRunningObject)) {
--- a/src/fun.c
+++ b/src/fun.c
@@ -13,7 +13,7 @@ static int options_hash_fun(char* key)
1313 return value % XYZSH_OPTION_MAX;
1414 }
1515
16-sObject* fun_new_from_gc(sObject* parent, BOOL user_object)
16+sObject* fun_new_from_gc(sObject* parent, BOOL user_object, BOOL no_stackframe)
1717 {
1818 sObject* self = gc_get_free_object(T_FUN, user_object);
1919
@@ -29,6 +29,8 @@ sObject* fun_new_from_gc(sObject* parent, BOOL user_object)
2929 SFUN(self).mOptions = MALLOC(sizeof(option_hash_it)*XYZSH_OPTION_MAX);
3030 memset(SFUN(self).mOptions, 0, sizeof(option_hash_it)*XYZSH_OPTION_MAX);
3131
32+ SFUN(self).mFlags = no_stackframe ? FUN_FLAGS_NO_STACKFRAME : 0;
33+
3234 return self;
3335 }
3436
@@ -47,10 +49,12 @@ sObject* fun_new_from_stack(sObject* parent)
4749 SFUN(self).mOptions = MALLOC(sizeof(option_hash_it)*XYZSH_OPTION_MAX);
4850 memset(SFUN(self).mOptions, 0, sizeof(option_hash_it)*XYZSH_OPTION_MAX);
4951
52+ SFUN(self).mFlags = 0;
53+
5054 return self;
5155 }
5256
53-sObject* fun_clone_from_stack_block_gc(sObject* block, BOOL user_object, sObject* parent)
57+sObject* fun_clone_from_stack_block_to_gc(sObject* block, BOOL user_object, sObject* parent, BOOL no_stackframe)
5458 {
5559 sObject* self = gc_get_free_object(T_FUN, user_object);
5660
@@ -65,10 +69,12 @@ sObject* fun_clone_from_stack_block_gc(sObject* block, BOOL user_object, sObject
6569 SFUN(self).mOptions = MALLOC(sizeof(option_hash_it)*XYZSH_OPTION_MAX);
6670 memset(SFUN(self).mOptions, 0, sizeof(option_hash_it)*XYZSH_OPTION_MAX);
6771
72+ SFUN(self).mFlags = no_stackframe ? FUN_FLAGS_NO_STACKFRAME : 0;
73+
6874 return self;
6975 }
7076
71-sObject* fun_clone_from_stack_block_stack(sObject* block, sObject* parent)
77+sObject* fun_clone_from_stack_block_to_stack(sObject* block, sObject* parent, BOOL no_stackframe)
7278 {
7379 sObject* self = stack_get_free_object(T_FUN);
7480
@@ -83,6 +89,8 @@ sObject* fun_clone_from_stack_block_stack(sObject* block, sObject* parent)
8389 SFUN(self).mOptions = MALLOC(sizeof(option_hash_it)*XYZSH_OPTION_MAX);
8490 memset(SFUN(self).mOptions, 0, sizeof(option_hash_it)*XYZSH_OPTION_MAX);
8591
92+ SFUN(self).mFlags = no_stackframe ? FUN_FLAGS_NO_STACKFRAME : 0;
93+
8694 return self;
8795 }
8896
--- a/src/hash.c
+++ b/src/hash.c
@@ -418,7 +418,7 @@ int hash_gc_children_mark(sObject* self)
418418 while(it) {
419419 sObject* item = it->mItem;
420420
421- if((item->mFlg & GC_MARK) == 0) {
421+ if(item && (item->mFlg & GC_MARK) == 0) {
422422 item->mFlg |= GC_MARK;
423423 count++;
424424 count += object_gc_children_mark(item);
--- a/src/list.c
+++ b/src/list.c
@@ -301,7 +301,7 @@ int list_gc_children_mark(sObject* self)
301301 for(it= SLIST(self).mEntryIt; it; it=it->mNextIt) {
302302 sObject* item = it->mItem;
303303
304- if((item->mFlg & GC_MARK) == 0) {
304+ if(item && (item->mFlg & GC_MARK) == 0) {
305305 item->mFlg |= GC_MARK;
306306 count ++;
307307 count += object_gc_children_mark(item);
--- a/src/run.c
+++ b/src/run.c
@@ -581,10 +581,28 @@ BOOL run_function(sObject* fun, sObject* nextin, sObject* nextout, sRunInfo* run
581581 sRunInfo* runinfo2 = SFUN(fun).mRunInfo;
582582 SFUN(fun).mRunInfo = runinfo;
583583
584- sObject* stackframe = UOBJECT_NEW_GC(8, gXyzshObject, "_stackframe", FALSE);
585- vector_add(gStackFrames, stackframe);
586- //uobject_init(stackframe);
587- SFUN(fun).mLocalObjects = stackframe;
584+ BOOL no_stackframe = SFUN(fun).mFlags & FUN_FLAGS_NO_STACKFRAME;
585+
586+ if(!no_stackframe) {
587+ sObject* stackframe = UOBJECT_NEW_GC(8, gXyzshObject, "_stackframe", FALSE);
588+ vector_add(gStackFrames, stackframe);
589+ //uobject_init(stackframe);
590+ SFUN(fun).mLocalObjects = stackframe;
591+ } else {
592+ sObject* stackframe_before = vector_item(gStackFrames, vector_count(gStackFrames)-1);
593+ sObject* stackframe = UOBJECT_NEW_GC(8, gXyzshObject, "_stackframe", FALSE);
594+ vector_add(gStackFrames, stackframe);
595+ //uobject_init(stackframe);
596+ SFUN(fun).mLocalObjects = stackframe;
597+
598+ uobject_it* it = uobject_loop_begin(stackframe_before);
599+ while(it) {
600+ sObject* object = uobject_loop_item(it);
601+ char* key = uobject_loop_key(it);
602+ uobject_put(stackframe, key, object);
603+ it = uobject_loop_next(it);
604+ }
605+ }
588606
589607 sObject* argv2 = VECTOR_NEW_GC(16, FALSE);
590608 int i;
@@ -631,7 +649,7 @@ BOOL run_function(sObject* fun, sObject* nextin, sObject* nextout, sRunInfo* run
631649
632650 (void)vector_pop_back(gStackFrames);
633651
634-runinfo->mRCode = rcode;
652+ runinfo->mRCode = rcode;
635653
636654 SFUN(fun).mLocalObjects = local_objects;
637655 SFUN(fun).mArgBlocks = arg_blocks;
@@ -688,7 +706,7 @@ static BOOL run_object(sObject* object, sObject* nextin, sObject* nextout, sRunI
688706
689707 case T_CLASS: {
690708 sCommand* command = runinfo->mCommand;
691- if(!run_function(object, nextin, nextout, runinfo, command->mArgsRuntime + 1, command->mArgsNumRuntime -1, command->mBlocks, command->mBlocksNum)){
709+ if(!run_function(object, nextin, nextout, runinfo, command->mArgsRuntime + 1, command->mArgsNumRuntime -1, command->mBlocks, command->mBlocksNum)) {
692710 return FALSE;
693711 }
694712 }
--- a/src/uobject.c
+++ b/src/uobject.c
@@ -326,7 +326,7 @@ int uobject_gc_children_mark(sObject* self)
326326 while(it) {
327327 sObject* item = it->mItem;
328328
329- if((item->mFlg & GC_MARK) == 0) {
329+ if(item && (item->mFlg & GC_MARK) == 0) {
330330 item->mFlg |= GC_MARK;
331331 count++;
332332
--- a/src/vector.c
+++ b/src/vector.c
@@ -231,7 +231,7 @@ int vector_gc_children_mark(sObject* self)
231231 for(i=0; i<SVECTOR(self).mCount; i++) {
232232 sObject* item = SVECTOR(self).mTable[i];
233233
234- if((item->mFlg & GC_MARK) == 0) {
234+ if(item && (item->mFlg & GC_MARK) == 0) {
235235 item->mFlg |= GC_MARK;
236236 count++;
237237
--- a/src/xyzsh.c
+++ b/src/xyzsh.c
@@ -85,7 +85,7 @@ static void xyzsh_read_rc()
8585
8686 void xyzsh_init(enum eAppType app_type, BOOL no_runtime_script)
8787 {
88- setenv("XYZSH_VERSION", "1.2.8", 1);
88+ setenv("XYZSH_VERSION", "1.2.9", 1);
8989 setenv("XYZSH_DATAROOTDIR", DATAROOTDIR, 1);
9090
9191 setlocale(LC_ALL, "");
--- a/src/xyzsh/block.h
+++ b/src/xyzsh/block.h
@@ -25,13 +25,11 @@ void sCommand_add_env_block(sCommand* self, sObject* block, BOOL double_dollar,
2525 void sCommand_add_env(sCommand* self, MANAGED char* name, MANAGED char* key, BOOL key_env, BOOL double_dollar);
2626 void sCommand_add_redirect_to_command(sCommand* self, MANAGED char* name, BOOL env, BOOL glob, int redirect);
2727
28-sObject* fun_clone_from_stack_block_gc(sObject* block, BOOL user_object, sObject* parent);
29-sObject* fun_clone_from_stack_block_stack(sObject* block, sObject* parent);
28+sObject* fun_clone_from_stack_block_to_gc(sObject* block, BOOL user_object, sObject* parent, BOOL no_stackframe);
29+sObject* fun_clone_from_stack_block_to_stack(sObject* block, sObject* parent, BOOL no_stackframe);
3030
31-sObject* make_stack_fun_from_stack_block(sObject* self);
32-
33-sObject* class_clone_from_stack_block_gc(sObject* block, BOOL user_object, sObject* parent);
34-sObject* class_clone_from_stack_block_stack(sObject* block, sObject* parent);
31+sObject* class_clone_from_stack_block_to_gc(sObject* block, BOOL user_object, sObject* parent, BOOL no_stackframe);
32+sObject* class_clone_from_stack_block_to_stack(sObject* block, sObject* parent, BOOL no_stackframe);
3533
3634 #endif
3735
--- a/src/xyzsh/xyzsh.h
+++ b/src/xyzsh/xyzsh.h
@@ -276,6 +276,8 @@ struct block_obj
276276 struct _sObject;
277277 struct _sRunInfo;
278278
279+#define FUN_FLAGS_NO_STACKFRAME 0x01
280+
279281 typedef struct
280282 {
281283 struct _sObject* mBlock;
@@ -287,6 +289,8 @@ typedef struct
287289
288290 option_hash_it* mOptions;
289291 struct _sRunInfo* mRunInfo;
292+
293+ char mFlags;
290294 } fun_obj;
291295
292296 typedef fun_obj class_obj;
@@ -498,8 +502,8 @@ void nfun_delete_gc(sObject* self);
498502 BOOL nfun_put_option_with_argument(sObject* self, MANAGED char* key);
499503 BOOL nfun_option_with_argument_item(sObject* self, char* key);
500504
501-sObject* fun_new_from_gc(sObject* parent, BOOL user_object);
502-#define FUN_NEW_GC(o, o2) fun_new_from_gc(o, o2)
505+sObject* fun_new_from_gc(sObject* parent, BOOL user_object, BOOL no_stackframe);
506+#define FUN_NEW_GC(o, o2, o3) fun_new_from_gc(o, o2, o3)
503507 void fun_delete_gc(sObject* self);
504508 int fun_gc_children_mark(sObject* self);
505509 #define FUN_NEW_STACK(o) fun_new_from_stack(o)
@@ -508,8 +512,8 @@ void fun_delete_stack(sObject* self);
508512 BOOL fun_put_option_with_argument(sObject* self, MANAGED char* key);
509513 BOOL fun_option_with_argument_item(sObject* self, char* key);
510514
511-sObject* class_new_from_gc(sObject* parent, BOOL user_object);
512-#define CLASS_NEW_GC(o, o2) class_fun_new_from_gc(o, o2)
515+sObject* class_new_from_gc(sObject* parent, BOOL user_object, BOOL no_stackframe);
516+#define CLASS_NEW_GC(o, o2, o3) class_fun_new_from_gc(o, o2, o3)
513517 void class_delete_gc(sObject* self);
514518 void class_delete_stack(sObject* self);
515519 BOOL class_option_with_argument_item(sObject* self, char* key);
--- a/xyzsh.xyzsh
+++ b/xyzsh.xyzsh
@@ -80,11 +80,11 @@ EOS > ~/.xyzsh/macro
8080 )
8181 )
8282
83-def times (
84- print 0 | var -local i
85- while(i | -lt $ARGV[0]) (
83+def times -copy-stackframe (
84+ print 0 | var -local _i
85+ while(_i | -lt $ARGV[0]) (
8686 | eval $(block)
87- ++ i
87+ ++ _i
8888 )
8989 )
9090