Skip to content

Commit

Permalink
4_11 fix - more static.
Browse files Browse the repository at this point in the history
  • Loading branch information
rsm-lisper committed May 24, 2024
1 parent 7b3dd63 commit a57aa99
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions chapter_4.functions_progr_structure/4_11.calc__static/stack.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

# define MAXVAL 128 /* max depth of val stack */

int sp = 0; /* next free stack position */
double val[MAXVAL]; /* value stack */
static int sp = 0; /* next free stack position */
static double val[MAXVAL]; /* value stack */


/* push: push f onto stack */
Expand Down
4 changes: 2 additions & 2 deletions chapter_4.functions_progr_structure/4_11.calc__static/vars.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@

double vars['Z'-'A'];
double last_val;
static double vars['Z'-'A'];
static double last_val;


/* set_var: set variable */
Expand Down

0 comments on commit a57aa99

Please sign in to comment.