get rid of K&R style args
authorTrevor Saunders <tbsaunde+binutils@tbsaunde.org>
Sun, 27 Mar 2016 08:30:31 +0000 (04:30 -0400)
committerTrevor Saunders <tbsaunde+binutils@tbsaunde.org>
Thu, 31 Mar 2016 05:04:00 +0000 (01:04 -0400)
gas/ChangeLog:

2016-03-31  Trevor Saunders  <tbsaunde+binutils@tbsaunde.org>

* cgen.c: Modernize the way functions declare arguments.
* config/tc-bfin.c: Likewise.
* config/tc-pdp11.c: Likewise.
* literal.c: Likewise.
* read.c: Likewise.
* stabs.c: Likewise.

gas/ChangeLog
gas/cgen.c
gas/config/tc-bfin.c
gas/config/tc-pdp11.c
gas/literal.c
gas/read.c
gas/stabs.c

index a84d8d0b2fd022fd399815437012ae1910d9d979..21450c268ff1a1d29b921294095f1457e272662c 100644 (file)
@@ -1,3 +1,12 @@
+2016-03-31  Trevor Saunders  <tbsaunde+binutils@tbsaunde.org>
+
+       * cgen.c: Modernize the way functions declare arguments.
+       * config/tc-bfin.c: Likewise.
+       * config/tc-pdp11.c: Likewise.
+       * literal.c: Likewise.
+       * read.c: Likewise.
+       * stabs.c: Likewise.
+
 2016-03-31  Trevor Saunders  <tbsaunde+binutils@tbsaunde.org>
 
        * config/tc-aarch64.c (aarch64_handle_align): Make the type of some
index bf8611fd0d7738782964887aeb495adf68e6b92f..41eaa55724069256ff4bc3f7b240a3066a28dead 100644 (file)
@@ -57,9 +57,7 @@ CGEN_CPU_DESC gas_cgen_cpu_desc;
    ??? Not currently used.  */
 
 void
-cgen_asm_record_register (name, number)
-     char *name;
-     int number;
+cgen_asm_record_register (char *name, int number)
 {
   /* Use symbol_create here instead of symbol_new so we don't try to
      output registers into the object file's symbol table.  */
@@ -102,10 +100,7 @@ gas_cgen_init_parse ()
 /* Queue a fixup.  */
 
 static void
-queue_fixup (opindex, opinfo, expP)
-     int           opindex;
-     int           opinfo;
-     expressionS * expP;
+queue_fixup (int opindex, int opinfo, expressionS *expP)
 {
   /* We need to generate a fixup for this expression.  */
   if (num_fixups >= GAS_CGEN_MAX_FIXUPS)
@@ -168,8 +163,7 @@ gas_cgen_initialize_saved_fixups_array ()
 }
 
 void
-gas_cgen_save_fixups (i)
-     int i;
+gas_cgen_save_fixups (int i)
 {
   if (i < 0 || i >= MAX_SAVED_FIXUP_CHAINS)
     {
@@ -184,8 +178,7 @@ gas_cgen_save_fixups (i)
 }
 
 void
-gas_cgen_restore_fixups (i)
-     int i;
+gas_cgen_restore_fixups (int i)
 {
   if (i < 0 || i >= MAX_SAVED_FIXUP_CHAINS)
     {
@@ -200,8 +193,7 @@ gas_cgen_restore_fixups (i)
 }
 
 void
-gas_cgen_swap_fixups (i)
-     int i;
+gas_cgen_swap_fixups (int i)
 {
   if (i < 0 || i >= MAX_SAVED_FIXUP_CHAINS)
     {
@@ -247,15 +239,9 @@ gas_cgen_swap_fixups (i)
    operand type.  We pick a BFD reloc type in md_apply_fix.  */
 
 fixS *
-gas_cgen_record_fixup (frag, where, insn, length, operand, opinfo, symbol, offset)
-     fragS *              frag;
-     int                  where;
-     const CGEN_INSN *    insn;
-     int                  length;
-     const CGEN_OPERAND * operand;
-     int                  opinfo;
-     symbolS *            symbol;
-     offsetT              offset;
+gas_cgen_record_fixup (fragS *frag, int where, const CGEN_INSN *insn,
+                      int length, const CGEN_OPERAND *operand, int opinfo,
+                      symbolS *symbol, offsetT offset)
 {
   fixS *fixP;
 
@@ -288,14 +274,9 @@ gas_cgen_record_fixup (frag, where, insn, length, operand, opinfo, symbol, offse
    operand type.  We pick a BFD reloc type in md_apply_fix.  */
 
 fixS *
-gas_cgen_record_fixup_exp (frag, where, insn, length, operand, opinfo, exp)
-     fragS *              frag;
-     int                  where;
-     const CGEN_INSN *    insn;
-     int                  length;
-     const CGEN_OPERAND * operand;
-     int                  opinfo;
-     expressionS *        exp;
+gas_cgen_record_fixup_exp (fragS *frag, int where, const CGEN_INSN *insn,
+                          int length, const CGEN_OPERAND *operand, int opinfo,
+                          expressionS *exp)
 {
   fixS *fixP;
 
@@ -344,19 +325,11 @@ static int expr_jmp_buf_p;
    The resulting value is stored in VALUEP.  */
 
 const char *
-gas_cgen_parse_operand (cd, want, strP, opindex, opinfo, resultP, valueP)
-
-#ifdef OBJ_COMPLEX_RELC
-     CGEN_CPU_DESC cd;
-#else
-     CGEN_CPU_DESC cd ATTRIBUTE_UNUSED;
-#endif
-     enum cgen_parse_operand_type want;
-     const char **strP;
-     int opindex;
-     int opinfo;
-     enum cgen_parse_operand_result *resultP;
-     bfd_vma *valueP;
+gas_cgen_parse_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
+                       enum cgen_parse_operand_type want, const char **strP,
+                       int opindex, int opinfo,
+                       enum cgen_parse_operand_result *resultP,
+                       bfd_vma *valueP)
 {
 #ifdef __STDC__
   /* These are volatile to survive the setjmp.  */
@@ -525,8 +498,7 @@ gas_cgen_parse_operand (cd, want, strP, opindex, opinfo, resultP, valueP)
    ??? This could be done differently by adding code to `expression'.  */
 
 void
-gas_cgen_md_operand (expressionP)
-     expressionS *expressionP ATTRIBUTE_UNUSED;
+gas_cgen_md_operand (expressionS *expressionP ATTRIBUTE_UNUSED)
 {
   /* Don't longjmp if we're not called from within cgen_parse_operand().  */
   if (expr_jmp_buf_p)
@@ -541,12 +513,8 @@ gas_cgen_md_operand (expressionP)
    The "result" is stored in RESULT if non-NULL.  */
 
 void
-gas_cgen_finish_insn (insn, buf, length, relax_p, result)
-     const CGEN_INSN *insn;
-     CGEN_INSN_BYTES_PTR buf;
-     unsigned int length;
-     int relax_p;
-     finished_insnS *result;
+gas_cgen_finish_insn (const CGEN_INSN *insn, CGEN_INSN_BYTES_PTR buf,
+                     unsigned int length, int relax_p, finished_insnS *result)
 {
   int i;
   int relax_operand;
@@ -868,10 +836,7 @@ make_right_shifted_expr (expressionS * exp,
    should handle them all.  */
 
 void
-gas_cgen_md_apply_fix (fixP, valP, seg)
-     fixS *   fixP;
-     valueT * valP;
-     segT     seg ATTRIBUTE_UNUSED;
+gas_cgen_md_apply_fix (fixS *fixP, valueT *valP, segT seg ATTRIBUTE_UNUSED)
 {
   char *where = fixP->fx_frag->fr_literal + fixP->fx_where;
   valueT value = * valP;
@@ -1042,9 +1007,7 @@ gas_cgen_pcrel_r_type (bfd_reloc_code_real_type r)
    FIXME: To what extent can we get all relevant targets to use this?  */
 
 arelent *
-gas_cgen_tc_gen_reloc (section, fixP)
-     asection * section ATTRIBUTE_UNUSED;
-     fixS *     fixP;
+gas_cgen_tc_gen_reloc (asection *section ATTRIBUTE_UNUSED, fixS *fixP)
 {
   bfd_reloc_code_real_type r_type = fixP->fx_r_type;
   arelent *reloc;
index 29754c15d33f06bff48a85e5e09964dfe9dddd4b..6dce28c16e2c4370d6c52ae113e4ffd55a8e9312 100644 (file)
@@ -791,9 +791,7 @@ md_apply_fix (fixS *fixP, valueT *valueP, segT seg ATTRIBUTE_UNUSED)
 
 /* Round up a section size to the appropriate boundary.  */
 valueT
-md_section_align (segment, size)
-     segT segment;
-     valueT size;
+md_section_align (segT segment, valueT size)
 {
   int boundary = bfd_get_section_alignment (stdoutput, segment);
   return ((size + (1 << boundary) - 1) & -(1 << boundary));
@@ -811,9 +809,7 @@ md_atof (int type, char * litP, int * sizeP)
    then it is done here.  */
 
 arelent *
-tc_gen_reloc (seg, fixp)
-     asection *seg ATTRIBUTE_UNUSED;
-     fixS *fixp;
+tc_gen_reloc (asection *seg ATTRIBUTE_UNUSED, fixS *fixp)
 {
   arelent *reloc;
 
@@ -844,9 +840,7 @@ tc_gen_reloc (seg, fixp)
     given a PC relative reloc.  */
 
 long
-md_pcrel_from_section (fixP, sec)
-     fixS *fixP;
-     segT sec;
+md_pcrel_from_section (fixS *fixP, segT sec)
 {
   if (fixP->fx_addsy != (symbolS *) NULL
       && (!S_IS_DEFINED (fixP->fx_addsy)
index 3d160cfb0977f90886a90de7ef36d0ce4b81950f..68e710f491d7ef6643bdb1f82cdcab6088c9662e 100644 (file)
@@ -279,9 +279,7 @@ md_apply_fix (fixS *fixP,
 }
 
 long
-md_chars_to_number (con, nbytes)
-     unsigned char con[];      /* Low order byte 1st.  */
-     int nbytes;               /* Number of bytes in the input.  */
+md_chars_to_number (unsigned char *con, int nbytes)
 {
   /* On a PDP-11, 0x1234 is stored as "\x12\x34", and
      0x12345678 is stored as "\x56\x78\x12\x34". It's
index b177296731c608ef3521f7265278f6df49a7f5f0..e2287c1cf624e6ff2e24b99feb07983a292faff9 100644 (file)
 #ifdef NEED_LITERAL_POOL
 
 valueT
-add_to_literal_pool (sym, addend, sec, size)
-     symbolS *sym;
-     valueT addend;
-     segT sec;
-     int size;
+add_to_literal_pool (symbolS *sym, valueT addend, segT sec, int size)
 {
   segT current_section = now_seg;
   int current_subsec = now_subseg;
index a22c7505efebe4bb108e43118be9c7d1e616c541..45023cae181677c09509e40f607d7c11c9c616dc 100644 (file)
@@ -4593,9 +4593,7 @@ emit_expr_fix (expressionS *exp, unsigned int nbytes, fragS *frag, char *p,
    BITFIELD_CONS_EXPRESSIONS.  */
 
 static void
-parse_bitfield_cons (exp, nbytes)
-     expressionS *exp;
-     unsigned int nbytes;
+parse_bitfield_cons (expressionS *exp, unsigned int nbytes)
 {
   unsigned int bits_available = BITS_PER_CHAR * nbytes;
   char *hold = input_line_pointer;
@@ -4780,9 +4778,7 @@ parse_mri_cons (expressionS *exp, unsigned int nbytes)
    To use this for a target, define REPEAT_CONS_EXPRESSIONS.  */
 
 static void
-parse_repeat_cons (exp, nbytes)
-     expressionS *exp;
-     unsigned int nbytes;
+parse_repeat_cons (expressionS *exp, unsigned int nbytes)
 {
   expressionS count;
   int i;
index 8d54f7373c48acacf641f0a7075f1a4e1a8b36ee..876ffa541f38fb6788873add254ba938f607c8f4 100644 (file)
@@ -134,10 +134,7 @@ get_stab_string_offset (const char *string, const char *stabstr_secname)
 
 /* Here instead of obj-aout.c because other formats use it too.  */
 void
-aout_process_stab (what, string, type, other, desc)
-     int what;
-     const char *string;
-     int type, other, desc;
+aout_process_stab (int what, const char *string, int type, int other, int desc)
 {
   /* Put the stab information in the symbol table.  */
   symbolS *symbol;
@@ -451,8 +448,7 @@ s_xstab (int what)
 /* Frob invented at RMS' request. Set the n_desc of a symbol.  */
 
 void
-s_desc (ignore)
-     int ignore ATTRIBUTE_UNUSED;
+s_desc (int ignore ATTRIBUTE_UNUSED)
 {
   char *name;
   char c;
This page took 0.048751 seconds and 4 git commands to generate.