[patch] tc-h8300.c: Make some functions and global variables static.

Kazu Hirata kazu@cs.umass.edu
Thu Nov 20 04:26:00 GMT 2003


Hi,

Attached is a patch to make some functions and global variables
static.

Built h8300 port without no new warning.  Committed as obvious.

Kazu Hirata

2003-11-19  Kazu Hirata  <kazu@cs.umass.edu>

	* config/tc-h8300.c: Make some functions and global
	variables static appropriately.

Index: tc-h8300.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-h8300.c,v
retrieving revision 1.39
diff -u -r1.39 tc-h8300.c
--- tc-h8300.c	20 Nov 2003 04:12:19 -0000	1.39
+++ tc-h8300.c	20 Nov 2003 04:22:30 -0000
@@ -43,23 +43,23 @@
 const char line_comment_chars[] = "#";
 const char line_separator_chars[] = "";
 
-void sbranch (int);
-void h8300hmode (int);
-void h8300smode (int);
-void h8300hnmode (int);
-void h8300snmode (int);
-void h8300sxmode (int);
-void h8300sxnmode (int);
+static void sbranch (int);
+static void h8300hmode (int);
+static void h8300smode (int);
+static void h8300hnmode (int);
+static void h8300snmode (int);
+static void h8300sxmode (int);
+static void h8300sxnmode (int);
 static void pint (int);
 
-int Hmode;
-int Smode;
-int Nmode;
-int SXmode;
+static int Hmode;
+static int Smode;
+static int Nmode;
+static int SXmode;
 
 #define PSIZE (Hmode && !Nmode ? L_32 : L_16)
 
-int bsize = L_8;		/* Default branch displacement.  */
+static int bsize = L_8;		/* Default branch displacement.  */
 
 struct h8_instruction
 {
@@ -70,9 +70,9 @@
   const struct h8_opcode *opcode;
 };
 
-struct h8_instruction *h8_instructions;
+static struct h8_instruction *h8_instructions;
 
-void
+static void
 h8300hmode (int arg ATTRIBUTE_UNUSED)
 {
   Hmode = 1;
@@ -83,7 +83,7 @@
 #endif
 }
 
-void
+static void
 h8300smode (int arg ATTRIBUTE_UNUSED)
 {
   Smode = 1;
@@ -94,7 +94,7 @@
 #endif
 }
 
-void
+static void
 h8300hnmode (int arg ATTRIBUTE_UNUSED)
 {
   Hmode = 1;
@@ -106,7 +106,7 @@
 #endif
 }
 
-void
+static void
 h8300snmode (int arg ATTRIBUTE_UNUSED)
 {
   Smode = 1;
@@ -118,7 +118,7 @@
 #endif
 }
 
-void
+static void
 h8300sxmode (int arg ATTRIBUTE_UNUSED)
 {
   Smode = 1;
@@ -130,7 +130,7 @@
 #endif
 }
 
-void
+static void
 h8300sxnmode (int arg ATTRIBUTE_UNUSED)
 {
   Smode = 1;
@@ -143,7 +143,7 @@
 #endif
 }
 
-void
+static void
 sbranch (int size)
 {
   bsize = size;



More information about the Binutils mailing list