ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/cvsroot/microscheme/scheme.c
(Generate patch)

Comparing cvsroot/microscheme/scheme.c (file contents):
Revision 1.40 by root, Mon Nov 30 05:19:01 2015 UTC vs.
Revision 1.42 by root, Mon Nov 30 06:19:18 2015 UTC

1393INTERFACE pointer 1393INTERFACE pointer
1394gensym (SCHEME_P) 1394gensym (SCHEME_P)
1395{ 1395{
1396 pointer x; 1396 pointer x;
1397 char name[40] = "gensym-"; 1397 char name[40] = "gensym-";
1398 xnum (name + 7, SCHEME_V->gensym_cnt); 1398 xnum (name + 7, ++SCHEME_V->gensym_cnt);
1399 1399
1400 return generate_symbol (SCHEME_A_ name); 1400 return generate_symbol (SCHEME_A_ name);
1401} 1401}
1402 1402
1403/* make symbol or number atom from string */ 1403/* make symbol or number atom from string */
2277 int c, curr_line = 0; 2277 int c, curr_line = 0;
2278 2278
2279 do 2279 do
2280 { 2280 {
2281 c = inchar (SCHEME_A); 2281 c = inchar (SCHEME_A);
2282
2282#if SHOW_ERROR_LINE 2283#if SHOW_ERROR_LINE
2283 if (c == '\n') 2284 if (ecb_expect_false (c == '\n'))
2284 curr_line++; 2285 curr_line++;
2285#endif 2286#endif
2287
2288 if (ecb_expect_false (c == EOF))
2289 return c;
2286 } 2290 }
2287 while (is_one_of (WHITESPACE, c)); 2291 while (is_one_of (WHITESPACE, c));
2288 2292
2289 /* record it */ 2293 /* record it */
2290#if SHOW_ERROR_LINE 2294#if SHOW_ERROR_LINE
2291 if (SCHEME_V->load_stack[SCHEME_V->file_i].kind & port_file) 2295 if (SCHEME_V->load_stack[SCHEME_V->file_i].kind & port_file)
2292 SCHEME_V->load_stack[SCHEME_V->file_i].rep.stdio.curr_line += curr_line; 2296 SCHEME_V->load_stack[SCHEME_V->file_i].rep.stdio.curr_line += curr_line;
2293#endif 2297#endif
2294 2298
2295 if (c != EOF)
2296 {
2297 backchar (SCHEME_A_ c); 2299 backchar (SCHEME_A_ c);
2298 return 1; 2300 return 1;
2299 }
2300 else
2301 return EOF;
2302} 2301}
2303 2302
2304/* get token */ 2303/* get token */
2305static int 2304static int
2306token (SCHEME_P) 2305token (SCHEME_P)

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines