aboutsummaryrefslogtreecommitdiff
path: root/bfd/bfd-in.h
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2002-01-30 18:12:17 +0000
committerNick Clifton <nickc@redhat.com>2002-01-30 18:12:17 +0000
commitb5f79c764c4d8fa336c92946eec8e2d8f4e9bffd (patch)
treee3d602d1f6122d9bdb7b714b3d9fab15ae1391e8 /bfd/bfd-in.h
parent6eb69eab2909778dc96bdb5dbb83d7756bee4601 (diff)
downloadgdb-b5f79c764c4d8fa336c92946eec8e2d8f4e9bffd.zip
gdb-b5f79c764c4d8fa336c92946eec8e2d8f4e9bffd.tar.gz
gdb-b5f79c764c4d8fa336c92946eec8e2d8f4e9bffd.tar.bz2
Tidy up formatting in bfd-in2.h
Diffstat (limited to 'bfd/bfd-in.h')
-rw-r--r--bfd/bfd-in.h75
1 files changed, 43 insertions, 32 deletions
diff --git a/bfd/bfd-in.h b/bfd/bfd-in.h
index 77a4abc..2f09a88 100644
--- a/bfd/bfd-in.h
+++ b/bfd/bfd-in.h
@@ -1,6 +1,6 @@
/* Main header file for the bfd library -- portable access to object files.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001
+ 2000, 2001, 2002
Free Software Foundation, Inc.
Contributed by Cygnus Support.
@@ -71,7 +71,7 @@ extern "C" {
#endif
#endif
-/* forward declaration */
+/* Forward declaration. */
typedef struct _bfd bfd;
/* To squelch erroneous compiler warnings ("illegal pointer
@@ -191,15 +191,17 @@ extern void bfd_fprintf_vma PARAMS ((bfd *, PTR, bfd_vma));
typedef unsigned int flagword; /* 32 bits of flags */
typedef unsigned char bfd_byte;
-/** File formats */
+/* File formats. */
-typedef enum bfd_format {
- bfd_unknown = 0, /* file format is unknown */
- bfd_object, /* linker/assember/compiler output */
- bfd_archive, /* object archive file */
- bfd_core, /* core dump */
- bfd_type_end} /* marks the end; don't use it! */
- bfd_format;
+typedef enum bfd_format
+{
+ bfd_unknown = 0, /* File format is unknown. */
+ bfd_object, /* Linker/assember/compiler output. */
+ bfd_archive, /* Object archive file. */
+ bfd_core, /* Core dump. */
+ bfd_type_end /* Marks the end; don't use it! */
+}
+bfd_format;
/* Values that may appear in the flags field of a BFD. These also
appear in the object_flags field of the bfd_target structure, where
@@ -258,7 +260,7 @@ typedef enum bfd_format {
memory. If this is set, iostream points to a bfd_in_memory struct. */
#define BFD_IN_MEMORY 0x800
-/* symbols and relocation */
+/* Symbols and relocation. */
/* A count of carsyms (canonical archive symbols). */
typedef unsigned long symindex;
@@ -282,33 +284,40 @@ typedef const struct reloc_howto_struct reloc_howto_type;
#define bfd_asymbol_flavour(x) (bfd_asymbol_bfd(x)->xvec->flavour)
/* A canonical archive symbol. */
-/* This is a type pun with struct ranlib on purpose! */
-typedef struct carsym {
+/* This is a type pun with struct ranlib on purpose! */
+typedef struct carsym
+{
char *name;
- file_ptr file_offset; /* look here to find the file */
-} carsym; /* to make these you call a carsymogen */
+ file_ptr file_offset; /* Look here to find the file. */
+}
+carsym; /* To make these you call a carsymogen. */
/* Used in generating armaps (archive tables of contents).
- Perhaps just a forward definition would do? */
-struct orl { /* output ranlib */
- char **name; /* symbol name */
- union {
+ Perhaps just a forward definition would do? */
+struct orl /* Output ranlib. */
+{
+ char **name; /* Symbol name. */
+ union
+ {
file_ptr pos;
bfd *abfd;
- } u; /* bfd* or file position */
- int namidx; /* index into string table */
+ } u; /* bfd* or file position. */
+ int namidx; /* Index into string table. */
};
-/* Linenumber stuff */
-typedef struct lineno_cache_entry {
- unsigned int line_number; /* Linenumber from start of function*/
- union {
- struct symbol_cache_entry *sym; /* Function name */
- bfd_vma offset; /* Offset into section */
+/* Linenumber stuff. */
+typedef struct lineno_cache_entry
+{
+ unsigned int line_number; /* Linenumber from start of function. */
+ union
+ {
+ struct symbol_cache_entry *sym; /* Function name. */
+ bfd_vma offset; /* Offset into section. */
} u;
-} alent;
+}
+alent;
-/* object and core file sections */
+/* Object and core file sections. */
#define align_power(addr, align) \
( ((addr) + ((1<<(align))-1)) & (-1 << (align)))
@@ -447,7 +456,7 @@ extern void bfd_hash_traverse PARAMS ((struct bfd_hash_table *,
#define COFF_SWAP_TABLE (PTR) &bfd_coff_std_swap_table
-/* User program access to BFD facilities */
+/* User program access to BFD facilities. */
/* Direct I/O routines, for programs which know more about the object
file than BFD does. Use higher level routines if possible. */
@@ -691,7 +700,8 @@ extern boolean bfd_sparclinux_size_dynamic_sections
struct _bfd_window_internal;
typedef struct _bfd_window_internal bfd_window_internal;
-typedef struct _bfd_window {
+typedef struct _bfd_window
+{
/* What the user asked for. */
PTR data;
bfd_size_type size;
@@ -702,7 +712,8 @@ typedef struct _bfd_window {
application; don't want to give the same region back when the
application wants two writable copies! */
struct _bfd_window_internal *i;
-} bfd_window;
+}
+bfd_window;
extern void bfd_init_window PARAMS ((bfd_window *));
extern void bfd_free_window PARAMS ((bfd_window *));