Fix missing-prototypes warnings (#1348)

This commit is contained in:
Marius Melzer 2019-01-22 01:39:44 +01:00 committed by Nguyen Anh Quynh
parent 171f28e1d4
commit 838b9aebd1
13 changed files with 23 additions and 6 deletions

View File

@ -43,6 +43,8 @@ struct MCOperand {
}; };
}; };
void MCOperand_Init(MCOperand *op);
bool MCOperand_isValid(const MCOperand *op); bool MCOperand_isValid(const MCOperand *op);
bool MCOperand_isReg(const MCOperand *op); bool MCOperand_isReg(const MCOperand *op);

View File

@ -24,6 +24,8 @@
#include "../../cs_priv.h" #include "../../cs_priv.h"
#include "../../utils.h" #include "../../utils.h"
#include "AArch64Disassembler.h"
#include "../../MCInst.h" #include "../../MCInst.h"
#include "../../MCInstrDesc.h" #include "../../MCInstrDesc.h"
#include "../../MCFixedLenDisassembler.h" #include "../../MCFixedLenDisassembler.h"

View File

@ -418,7 +418,7 @@ static void get_with_index_address_mode(m68k_info *info, cs_m68k_op* op, uint in
} }
/* Make string of effective address mode */ /* Make string of effective address mode */
void get_ea_mode_op(m68k_info *info, cs_m68k_op* op, uint instruction, uint size) static void get_ea_mode_op(m68k_info *info, cs_m68k_op* op, uint instruction, uint size)
{ {
// default to memory // default to memory

View File

@ -16,6 +16,8 @@
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "M68KInstPrinter.h"
#include "M68KDisassembler.h" #include "M68KDisassembler.h"
#include "../../cs_priv.h" #include "../../cs_priv.h"
@ -70,7 +72,7 @@ static const char* s_instruction_names[] = {
#ifndef CAPSTONE_DIET #ifndef CAPSTONE_DIET
const char* getRegName(m68k_reg reg) static const char* getRegName(m68k_reg reg)
{ {
return s_reg_names[(int)reg]; return s_reg_names[(int)reg];
} }
@ -126,7 +128,7 @@ static void registerPair(SStream* O, const cs_m68k_op* op)
s_reg_names[M68K_REG_D0 + op->reg_pair.reg_1]); s_reg_names[M68K_REG_D0 + op->reg_pair.reg_1]);
} }
void printAddressingMode(SStream* O, unsigned int pc, const cs_m68k* inst, const cs_m68k_op* op) static void printAddressingMode(SStream* O, unsigned int pc, const cs_m68k* inst, const cs_m68k_op* op)
{ {
switch (op->address_mode) { switch (op->address_mode) {
case M68K_AM_NONE: case M68K_AM_NONE:

View File

@ -11,7 +11,6 @@
struct SStream; struct SStream;
void M68K_init(MCRegisterInfo *MRI); void M68K_init(MCRegisterInfo *MRI);
void M68K_printInst(MCInst* MI, struct SStream* O, void* Info); void M68K_printInst(MCInst* MI, struct SStream* O, void* Info);
const char* M68K_reg_name(csh handle, unsigned int reg); const char* M68K_reg_name(csh handle, unsigned int reg);
void M68K_get_insn_id(cs_struct* h, cs_insn* insn, unsigned int id); void M68K_get_insn_id(cs_struct* h, cs_insn* insn, unsigned int id);
@ -20,4 +19,3 @@ const char* M68K_group_name(csh handle, unsigned int id);
void M68K_post_printer(csh handle, cs_insn* flat_insn, char* insn_asm, MCInst* mci); void M68K_post_printer(csh handle, cs_insn* flat_insn, char* insn_asm, MCInst* mci);
#endif #endif

View File

@ -21,9 +21,10 @@
#include "capstone/platform.h" #include "capstone/platform.h"
#include "MipsDisassembler.h"
#include "../../utils.h" #include "../../utils.h"
#include "../../MCInst.h"
#include "../../MCRegisterInfo.h" #include "../../MCRegisterInfo.h"
#include "../../SStream.h" #include "../../SStream.h"

View File

@ -5,6 +5,7 @@
#define CS_MIPSDISASSEMBLER_H #define CS_MIPSDISASSEMBLER_H
#include "capstone/capstone.h" #include "capstone/capstone.h"
#include "../../MCInst.h"
#include "../../MCRegisterInfo.h" #include "../../MCRegisterInfo.h"
void Mips_init(MCRegisterInfo *MRI); void Mips_init(MCRegisterInfo *MRI);

View File

@ -19,6 +19,8 @@
#include "../../cs_priv.h" #include "../../cs_priv.h"
#include "../../utils.h" #include "../../utils.h"
#include "PPCDisassembler.h"
#include "../../MCInst.h" #include "../../MCInst.h"
#include "../../MCInstrDesc.h" #include "../../MCInstrDesc.h"
#include "../../MCFixedLenDisassembler.h" #include "../../MCFixedLenDisassembler.h"

View File

@ -19,6 +19,8 @@
#include "../../cs_priv.h" #include "../../cs_priv.h"
#include "../../utils.h" #include "../../utils.h"
#include "SparcDisassembler.h"
#include "../../MCInst.h" #include "../../MCInst.h"
#include "../../MCInstrDesc.h" #include "../../MCInstrDesc.h"
#include "../../MCFixedLenDisassembler.h" #include "../../MCFixedLenDisassembler.h"

View File

@ -19,6 +19,8 @@
#include "../../cs_priv.h" #include "../../cs_priv.h"
#include "../../utils.h" #include "../../utils.h"
#include "SystemZDisassembler.h"
#include "../../MCInst.h" #include "../../MCInst.h"
#include "../../MCInstrDesc.h" #include "../../MCInstrDesc.h"
#include "../../MCFixedLenDisassembler.h" #include "../../MCFixedLenDisassembler.h"

View File

@ -8,6 +8,8 @@
#include "../../cs_priv.h" #include "../../cs_priv.h"
#include "../../utils.h" #include "../../utils.h"
#include "TMS320C64xDisassembler.h"
#include "../../MCInst.h" #include "../../MCInst.h"
#include "../../MCInstrDesc.h" #include "../../MCInstrDesc.h"
#include "../../MCFixedLenDisassembler.h" #include "../../MCFixedLenDisassembler.h"

View File

@ -41,6 +41,7 @@
#include "../../SStream.h" #include "../../SStream.h"
#include "../../MCRegisterInfo.h" #include "../../MCRegisterInfo.h"
#include "X86InstPrinter.h"
#include "X86Mapping.h" #include "X86Mapping.h"
#define GET_INSTRINFO_ENUM #define GET_INSTRINFO_ENUM

View File

@ -19,6 +19,8 @@
#include "../../cs_priv.h" #include "../../cs_priv.h"
#include "../../utils.h" #include "../../utils.h"
#include "XCoreDisassembler.h"
#include "../../MCInst.h" #include "../../MCInst.h"
#include "../../MCInstrDesc.h" #include "../../MCInstrDesc.h"
#include "../../MCFixedLenDisassembler.h" #include "../../MCFixedLenDisassembler.h"