[Tinyos-commits] CVS: tinyos-1.x/tos/lib/VM/languages/motlle/standalone/runtime files.c, 1.3, 1.4 support.c, 1.3, 1.4

David Gay idgay at users.sourceforge.net
Tue Oct 25 15:33:23 PDT 2005


Update of /cvsroot/tinyos/tinyos-1.x/tos/lib/VM/languages/motlle/standalone/runtime
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26029/standalone/runtime

Modified Files:
	files.c support.c 
Log Message:
-s option to mload to specify scheme code


Index: files.c
===================================================================
RCS file: /cvsroot/tinyos/tinyos-1.x/tos/lib/VM/languages/motlle/standalone/runtime/files.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** files.c	19 May 2005 17:23:48 -0000	1.3
--- files.c	25 Oct 2005 22:33:21 -0000	1.4
***************
*** 104,108 ****
    frame->f = f;
  
!   read_from_file(f);
    compile_and_run(NULL, globals, fname, NULL, FALSE);
  
--- 104,108 ----
    frame->f = f;
  
!   read_from_file(f, FALSE);
    compile_and_run(NULL, globals, fname, NULL, FALSE);
  

Index: support.c
===================================================================
RCS file: /cvsroot/tinyos/tinyos-1.x/tos/lib/VM/languages/motlle/standalone/runtime/support.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** support.c	14 Oct 2005 00:20:31 -0000	1.3
--- support.c	25 Oct 2005 22:33:21 -0000	1.4
***************
*** 64,68 ****
    TYPEIS(code, type_string);
  
!   read_from_string(code->str);
    pmemory = new_block();
    if ((f = parse(pmemory)))
--- 64,68 ----
    TYPEIS(code, type_string);
  
!   read_from_string(code->str, FALSE);
    pmemory = new_block();
    if ((f = parse(pmemory)))
***************
*** 92,96 ****
  
    LOCALSTR(fname, nicename);
!   read_from_file(f);
  
    pmemory = new_block();
--- 92,96 ----
  
    LOCALSTR(fname, nicename);
!   read_from_file(f, FALSE);
  
    pmemory = new_block();
***************
*** 476,481 ****
  
  UNSAFEOP("string_compile", string_compile,
! "gstate s -> fn. Compile s for global state context gstate",
! 	 2, (struct global_state *gstate, struct string *s), 0)
  {
    block_t nb;
--- 476,482 ----
  
  UNSAFEOP("string_compile", string_compile,
! "gstate s b -> fn. Compile s for global state context gstate.\n\
! If b is true, compile as scheme string.",
! 	 3, (struct global_state *gstate, struct string *s, value is_scheme), 0)
  {
    block_t nb;
***************
*** 485,489 ****
  
    nb = new_block();
!   read_from_string(bstrdup(nb, s->str));
    compile_and_run(nb, gstate, "<remote>", NULL, TRUE);
    return PRIMITIVE_STOLE_CC;
--- 486,490 ----
  
    nb = new_block();
!   read_from_string(bstrdup(nb, s->str), istrue(is_scheme));
    compile_and_run(nb, gstate, "<remote>", NULL, TRUE);
    return PRIMITIVE_STOLE_CC;
***************
*** 491,496 ****
  
  UNSAFEOP("file_compile", file_compile,
! "gstate s -> fn. Compile file s for global state context gstate",
! 	 2, (struct global_state *gstate, struct string *s), 0)
  {
    block_t nb;
--- 492,498 ----
  
  UNSAFEOP("file_compile", file_compile,
! "gstate s b -> fn. Compile file s for global state context gstate.\n\
! If b is true, compile as scheme string.",
! 	 3, (struct global_state *gstate, struct string *s, value is_scheme), 0)
  {
    block_t nb;
***************
*** 506,510 ****
        nb = new_block();
        fname = bstrdup(nb, s->str);
!       read_from_file(f);
        compile_and_run(nb, gstate, fname, NULL, TRUE);
        return PRIMITIVE_STOLE_CC;
--- 508,512 ----
        nb = new_block();
        fname = bstrdup(nb, s->str);
!       read_from_file(f, istrue(is_scheme));
        compile_and_run(nb, gstate, fname, NULL, TRUE);
        return PRIMITIVE_STOLE_CC;



More information about the Tinyos-commits mailing list