change some names

This commit is contained in:
ceriel 1989-01-26 13:24:23 +00:00
parent 3373e11923
commit e92f8ac398
8 changed files with 29 additions and 30 deletions

View file

@ -1,9 +1,9 @@
#define CODE_EXPANDER #define CODE_EXPANDER
#include <em.h> #include <em.h>
extern int busy; extern int B_busy;
int C_busy() int C_busy()
{ {
return( busy); return( B_busy);
} }

View file

@ -2,13 +2,13 @@
#include <em.h> #include <em.h>
#include <assert.h> #include <assert.h>
extern int busy; extern int B_busy;
C_close() C_close()
{ {
assert( busy); assert( B_busy);
end_back(); end_back();
close_back(); close_back();
busy = 0; B_busy = 0;
} }

View file

@ -2,7 +2,7 @@
#include <em.h> #include <em.h>
#include "back.h" #include "back.h"
extern int procno; extern int B_procno;
C_df_ilb( l) C_df_ilb( l)
label l; label l;
@ -10,6 +10,6 @@ label l;
char *s; char *s;
swtxt(); swtxt();
symbol_definition(s = extnd_ilb( l, procno)); symbol_definition(s = extnd_ilb( l, B_procno));
set_local_visible(s); set_local_visible(s);
} }

View file

@ -2,8 +2,8 @@
#include <em.h> #include <em.h>
#include "back.h" #include "back.h"
extern int locals_created; extern int B_locals_created;
extern int procno; extern int B_procno;
C_end( l) C_end( l)
arith l; arith l;
@ -12,12 +12,12 @@ arith l;
swtxt(); swtxt();
if ( !locals_created) { if ( !B_locals_created) {
p = extnd_pro( procno); p = extnd_pro( B_procno);
symbol_definition( p); symbol_definition( p);
set_local_visible( p); set_local_visible( p);
locals( l); locals( l);
jump( extnd_start( procno)); jump( extnd_start( B_procno));
} }
} }

View file

@ -2,9 +2,9 @@
#include <em.h> #include <em.h>
#include <assert.h> #include <assert.h>
extern int locals_created; extern int B_locals_created;
C_end_narg() C_end_narg()
{ {
assert( locals_created); assert( B_locals_created);
} }

View file

@ -3,12 +3,12 @@
#include <assert.h> #include <assert.h>
#include <system.h> #include <system.h>
extern int busy; extern int B_busy;
int C_open( filename) int C_open( filename)
char *filename; char *filename;
{ {
assert( !busy); assert( !B_busy);
if ( !open_back( filename)) { if ( !open_back( filename)) {
fprint( STDERR, "Couldn't open %s\n", filename); fprint( STDERR, "Couldn't open %s\n", filename);

View file

@ -2,8 +2,8 @@
#include <em.h> #include <em.h>
#include "back.h" #include "back.h"
extern int locals_created; extern int B_locals_created;
extern int procno; extern int B_procno;
C_pro( s, l) C_pro( s, l)
char *s; char *s;
@ -12,8 +12,8 @@ arith l;
swtxt(); swtxt();
symbol_definition( extnd_name( s)); symbol_definition( extnd_name( s));
procno++; B_procno++;
prolog(); prolog();
locals(l); locals(l);
locals_created = 1; B_locals_created = 1;
} }

View file

@ -2,26 +2,25 @@
#include <em.h> #include <em.h>
#include "back.h" #include "back.h"
extern int locals_created; extern int B_locals_created;
extern int procno; extern int B_procno;
C_pro_narg( s) C_pro_narg( s)
char*s; char*s;
/* Het aantal locale variabelen is nog niet bekend, maar het stack-frame moet /* The number of locals is unknown, but the stackframe must be made anyway.
* nu wel gemaakt worden! Oplossing : Pas bij bij C_end() is het aantal locale * Solution: jump to end of procedure, where C_end() will generate code to
* variabelen bekend dus nu een "jump" genereren en bij C_end() prolog() aan- * create the stackframe, and also will generate code to jump back.
* roepen en daarna terug-jump-en naar het begin van de EM-procedure.
*/ */
{ {
char *ss; char *ss;
swtxt(); swtxt();
symbol_definition( extnd_name( s)); symbol_definition( extnd_name( s));
procno++; B_procno++;
prolog(); prolog();
locals_created = 0; B_locals_created = 0;
jump( extnd_pro( procno)); jump( extnd_pro( B_procno));
symbol_definition( ss = extnd_start( procno)); symbol_definition( ss = extnd_start( B_procno));
set_local_visible( ss); set_local_visible( ss);
} }