1. 13 Jun, 2017 5 commits
  2. 12 Jun, 2017 29 commits
    • Philipp Stephani's avatar
      Print module structure sizes when initializing test module · 52c846d4
      Philipp Stephani authored
      * test/data/emacs-module/mod-test.c (emacs_module_init): Print
      compile-time and runtime sizes of module structures to ease debugging
      52c846d4
    • Glenn Morris's avatar
      Small portability fix for emacs-module.h (bug#27346) · 69899d4a
      Glenn Morris authored
      * src/emacs-module.h (EMACS_ATTRIBUTE_NONNULL) [!__has_attribute]:
      Avoid 'error: missing binary operator before token "("'.
      69899d4a
    • Glenn Morris's avatar
      Give a more informative failure in module assertion test · 73b50a10
      Glenn Morris authored
      * test/src/emacs-module-tests.el (module--test-assertions):
      Rephrase final check to give a more informative failure.
      73b50a10
    • Philipp Stephani's avatar
      Fix off-by-one error · 1da7bc7e
      Philipp Stephani authored
      * test/data/emacs-module/mod-test.c (emacs_module_init): Fix
      off-by-one error.
      1da7bc7e
    • Glenn Morris's avatar
      Clean up after module assertion tests · ab2116c9
      Glenn Morris authored
      * test/src/emacs-module-tests.el (module--test-assertions):
      Use a temporary directory to contain any core dumps.
      ab2116c9
    • Glenn Morris's avatar
      Small improvement for module assertion test · 1612d3dd
      Glenn Morris authored
      * test/src/emacs-module-tests.el (module--test-assertions):
      Don't rely on the precise form of an "Abort" message.
      1612d3dd
    • Glenn Morris's avatar
      Improve previous test/data/emacs-module/Makefile change · 6096f811
      Glenn Morris authored
      * test/data/emacs-module/Makefile.in (clean):
      Avoid doing unpleasant things if run in a build without modules.
      6096f811
    • Glenn Morris's avatar
      Small improvements for test/data/emacs-module/Makefile · 5f25857f
      Glenn Morris authored
      * test/data/emacs-module/Makefile.in (%.o):
      Fix emacs-module dependency.
      (SECONDARY): Stop make automatically deleting *.o.
      (clean): New rule.
      5f25857f
    • Glenn Morris's avatar
      710ed389
    • Alan Third's avatar
      Note how fullscreen differs on the NS port · 1d1f3010
      Alan Third authored
      doc/lispref/frames.texi (Size Parameters):
      doc/emacs/frames.texi (Tool Bars): Add a description of how macOS
      hides the tool-bar and menu-bar in fullscreen.
      1d1f3010
    • Alan Third's avatar
      Add no-focus-on-map to NS build (bug#25408) · 0f24ad7b
      Alan Third authored
      * src/nsfns.m (ns_frame_parm_handlers): Add x_set_no_focus_on_map.
      (x-create-frame): Check for no-focus-on-map.
      * src/nsterm.h (x_set_no_focus_on_map): New function.
      * src/nsterm.m (x_set_no_focus_on_map): New function.
      (ns_raise_frame): Add parameter for specifying whether to focus the
      frame.
      (ns_frame_raise_lower):
      (x_make_frame_visible): Handle new parameter for ns_raise_frame.
      0f24ad7b
    • Paul Eggert's avatar
      _Noreturn not noreturn · 6b9618e8
      Paul Eggert authored
      _Noreturn is more portable to non-C11 platforms.  See:
      https://www.gnu.org/software/gnulib/manual/html_node/stdnoreturn_002eh.html
      * src/emacs-module.c: Use _Noreturn, not noreturn.  No need to
      include <stdnoreturn.h>.  Reindent to fit in 80 columns.
      6b9618e8
    • Glenn Morris's avatar
      Update make-dist for recent test/ changes · d92599d3
      Glenn Morris authored
      * make-dist: No longer distribute test/data/emacs-module/Makefile.
      d92599d3
    • Michael Albinus's avatar
    • Michael Albinus's avatar
      Handle port and domain in Tramp's password cache · 7dfc8353
      Michael Albinus authored
      * doc/misc/tramp.texi (Password handling): Explain port and
      domain handling in authinfo.
      
      * lisp/net/tramp.el (tramp-process-actions, tramp-clear-passwd):
      * lisp/net/tramp-gvfs.el (tramp-gvfs-handler-askpassword):
      * lisp/net/tramp-sh.el (tramp-do-copy-or-rename-file-out-of-band)
      (tramp-maybe-open-connection):
      * lisp/net/tramp-smb.el (tramp-smb-handle-copy-directory)
      (tramp-smb-handle-file-acl, tramp-smb-handle-set-file-acl)
      (tramp-smb-maybe-open-connection): Handle also domain and port.
      7dfc8353
    • Eli Zaretskii's avatar
      Avoid compilation warnings with pre-C99 libc · e6f47a9d
      Eli Zaretskii authored
      * src/emacs-module.c (module_free_global_ref)
      (module_assert_runtime, module_assert_env, value_to_lisp): Use 'pD'
      instead of C99 't' format descriptor.
      e6f47a9d
    • Philipp Stephani's avatar
      Flush all output streams before aborting · d29a9dae
      Philipp Stephani authored
      Maybe the stdout buffer still contains something interesting that
      should be flushed.
      
      * src/emacs-module.c (module_abort): Flush all output streams before
      aborting.
      d29a9dae
    • Philipp Stephani's avatar
      Remove an assertion that doesn't test Emacs invariants · 655439b7
      Philipp Stephani authored
      * src/emacs-module.c (module_copy_string_contents): Remove an
      assertion that doesn't test Emacs invariants.
      655439b7
    • Philipp Stephani's avatar
      Test module: add necessary version checks · 272235c1
      Philipp Stephani authored
      * test/data/emacs-module/mod-test.c (emacs_module_init): Add necessary
      version checks.
      272235c1
    • Philipp Stephani's avatar
      Use additional CFLAGS from configure · d7f6477c
      Philipp Stephani authored
      d7f6477c
    • Philipp Stephani's avatar
      Use Autoconf to generate the test module Makefile · c90a97ad
      Philipp Stephani authored
      This makes it easier to pass compilation flags around.
      
      * configure.ac: Also build test module Makefile.
      
      * test/data/emacs-module/Makefile.in: New makefile template.
      
      * test/Makefile.in ($(test_module)): No longer necessary to pass
      @MODULES_SUFFIX@ around.
      
      * .gitignore: Test module Makefile can now be ignored.
      c90a97ad
    • Philipp Stephani's avatar
      Also compile test module as C11 · 909dfaf3
      Philipp Stephani authored
      * test/data/emacs-module/Makefile (CFLAGS): Compile test module as C11
      909dfaf3
    • Philipp Stephani's avatar
      Implement module assertions for users · cf971327
      Philipp Stephani authored
      Add a new command-line option '-module-assertions' that users can
      enable developing or debugging a module.  If this option is present,
      Emacs performs additional checks to verify that modules fulfill their
      requirements.  These checks are expensive and crash Emacs if modules
      are invalid, so disable them by default.
      
      This is a command-line option instead of an ordinary variable because
      changing it while Emacs is running would cause data structure
      imbalances.
      
      * src/emacs.c (main): New command line option '-module-assertions'.
      
      * src/emacs-module.c (module_assert_main_thread)
      (module_assert_runtime, module_assert_env, module_assert_value):
      New functions to assert module requirements.
      (syms_of_module): New uninterned variable 'module-runtimes'.
      (init_module_assertions, in_main_thread, module_abort): New helper
      functions.
      (initialize_environment): Initialize value list.  If assertions are
      enabled, use a heap-allocated environment object.
      (finalize_environment): Add assertion that environment list is never
      empty.
      (finalize_runtime_unwind): Pop module runtime object stack.
      (value_to_lisp): Assert that the value is valid.
      (lisp_to_value): Record new value if assertions are enabled.
      (mark_modules): Mark allocated object list.
      (MODULE_FUNCTION_BEGIN_NO_CATCH)
      (module_non_local_exit_check, module_non_local_exit_clear)
      (module_non_local_exit_get, module_non_local_exit_signal)
      (module_non_local_exit_throw): Assert thread and environment.
      (module_get_environment): Assert thread and runtime.
      (module_make_function, module_funcall, module_intern)
      (module_funcall, module_make_integer, module_make_float)
      (module_make_string, module_make_user_ptr, module_vec_get)
      (funcall_module, Fmodule_load): Adapt callers.
      (module_make_global_ref): If assertions are enabled, use the global
      environment to store global values.
      (module_free_global_ref): Remove value from global value list.
      
      * test/Makefile.in (EMACSOPT): Enable module assertions when testing
      modules.
      
      * test/data/emacs-module/mod-test.c (Fmod_test_invalid_store)
      (Fmod_test_invalid_load): New functions to test module assertions.
      (emacs_module_init): Bind the new functions.
      
      * test/src/emacs-module-tests.el (mod-test-emacs): New constant for
      the Emacs binary file.
      (mod-test-file): New constant for the test module file name.
      (module--test-assertions): New unit test.
      cf971327
    • Philipp Stephani's avatar
      emacs-module: Use __attribute__((nonnull)) · b49dd3b0
      Philipp Stephani authored
      Annotate all parameters with __attribute__((nonnull)) that may not be
      NULL.
      b49dd3b0
    • Philipp Stephani's avatar
      Explicitly require C11 or C++11 in emacs-module.h · 9dc6e93b
      Philipp Stephani authored
      We already implicitly require them by including stdbool.h.  Just make
      the error message a bit clearer, and remove an unnecessary version
      comparison.
      9dc6e93b
    • Philipp Stephani's avatar
      Add missing 'require' forms to prevent compiler warnings. · 3f89df5c
      Philipp Stephani authored
      * lisp/eshell/esh-ext.el (esh-arg, esh-proc): Add missing
      requirements.
      3f89df5c
    • Paul Eggert's avatar
      Merge from gnulib · 07ab8374
      Paul Eggert authored
      This incorporates:
      2017-06-11 getopt-posix: port to glibc 2.25.90
      2017-06-04 same-inode: port better to VMS 8.2 and later
      * doc/misc/texinfo.tex, lib/getopt-pfx-core.h, lib/getopt-pfx-ext.h:
      * m4/sys_types_h.m4: Copy from gnulib.
      07ab8374
    • Paul Eggert's avatar
      Remove Lisp_Misc_Float · bb534f6a
      Paul Eggert authored
      * src/data.c (Ftype_of): Do not worry about Lisp_Misc_Float.
      * src/lisp.h (Lisp_Misc_Float): Remove.  This placeholder has been
      unused for two decades; if we ever want to change floats to be a
      misc type we can bring it back then.
      bb534f6a
    • Paul Eggert's avatar
      Make two symbols private to emacs-module.c · d0ff364f
      Paul Eggert authored
      * src/lisp.h (allocate_module_function, XSET_MODULE_FUNCTION):
      Move from here ...
      * src/emacs-module.c: ... to here.
      d0ff364f
  3. 11 Jun, 2017 6 commits