*** empty log message ***

This commit is contained in:
hyung-hwan 2006-04-21 06:06:32 +00:00
parent bf5bc1cfab
commit 48bfdf6e2c
2 changed files with 38 additions and 3 deletions

View File

@ -1,5 +1,5 @@
/*
* $Id: awk_i.h,v 1.4 2006-04-16 04:31:38 bacon Exp $
* $Id: awk_i.h,v 1.5 2006-04-21 06:06:32 bacon Exp $
*/
#ifndef _XP_AWK_AWKI_H_
@ -20,6 +20,39 @@
typedef struct xp_awk_chain_t xp_awk_chain_t;
/*
*
struct xp_awk_parse_t
{
int opt;
};
struct xp_awk_run_t
{
int opt;
};
awk = xp_awk_open ();
xp_awk_parse (awk, "source");
thr = create_thread (5);
thr[0]->xp_awk_run (awk, "data1");
thr[1]->xp_awk_run (awk, "data2");
thr[2]->xp_awk_run (awk, "data3");
xp_awk_setcallback (void* __command_callback (int cmd, void* arg), void* arg);
xp_awk_run (awk)
{
run_stack = malloc (run_stack_size);
while ()
{
if (command_callback) if (command_callback (XP_AWK_ABORT) == yes) break;
run with run_stack
}
}
*/
struct xp_awk_t
{
/* options */

View File

@ -1,5 +1,5 @@
/*
* $Id: run.c,v 1.64 2006-04-20 16:17:01 bacon Exp $
* $Id: run.c,v 1.65 2006-04-21 06:06:32 bacon Exp $
*/
#include <xp/awk/awk_i.h>
@ -28,6 +28,7 @@
#define EXIT_CONTINUE 2
#define EXIT_FUNCTION 3
#define EXIT_GLOBAL 4
#define EXIT_ABORT 5
#define PANIC(awk,code) \
do { (awk)->errnum = (code); return XP_NULL; } while (0)
@ -239,7 +240,8 @@ int xp_awk_run (xp_awk_t* awk)
(xp_awk_nde_blk_t*)awk->tree.begin) == -1) n = -1;
}
while (awk->run.exit_level != EXIT_GLOBAL)
while (awk->run.exit_level != EXIT_GLOBAL &&
awk->run.exit_level != EXIT_ABORT)
{
awk->run.exit_level = EXIT_NONE;