Include-file tweaks for modules

* src/dynlib.c, src/emacs-module.c: Include <config.h> first.
* src/dynlib.h: Do not include config.h.
It’s every .c file’s responsibility to include config.h first.
* src/emacs-module.c: Include emacs-module.h immediately after
config.h, to test that emacs-module.h doesn’t depend on
include files other than config.h.
This commit is contained in:
Paul Eggert 2015-11-20 00:40:45 -08:00
parent aa7dac8998
commit c69cec404c
3 changed files with 6 additions and 3 deletions

View file

@ -24,6 +24,8 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
If you think the abstraction is too leaky use libltdl (libtool),
don't reinvent the wheel by fixing this one. */
#include <config.h>
#include "dynlib.h"
#if defined _WIN32

View file

@ -20,7 +20,6 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
#ifndef DYNLIB_H
#define DYNLIB_H
#include <config.h>
#include <stdbool.h>
typedef void *dynlib_handle_ptr;

View file

@ -17,14 +17,16 @@ GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
#include <config.h>
#include "emacs-module.h"
#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>
#include <stdio.h>
#include <config.h>
#include "lisp.h"
#include "emacs-module.h"
#include "dynlib.h"
#include "coding.h"
#include "verify.h"