all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Drew Adams <drew.adams@oracle.com>
To: 28113@debbugs.gnu.org
Subject: bug#28113: 25.2; `ignore-errors' around `require'
Date: Wed, 16 Aug 2017 13:11:56 -0700 (PDT)	[thread overview]
Message-ID: <07193cef-cdb9-4f39-a44e-920cf072411b@default> (raw)

I'm guessing that there is not a bug here, as this seems to happen for
all Emacs versions I have.  But it seems like it should be a bug.  I
would like to understand it, in any case.

In crosshairs.el I require vline.el and hl-line+.el:

(require 'vline)
(require 'hl-line+)

In start.el I wrap requiring crosshairs.el with `ignore-errors'
(`condition-case', for compatibility with older releases):

(condition-case nil
   (require 'crosshairs nil t)
  (error nil))

If I remove vline.el from my load-path and then try to load
crosshairs.el then I get this error:

Debugger entered--Lisp error: (file-error "Cannot open load file" "No such file or directory" "vline")
  require(vline)
  byte-code("..." [require vline custom-declare-group column-highlight nil "..."] 20)
  require(col-highlight)
  byte-code("..." [require hl-line+ col-highlight custom-declare-group crosshairs nil "..." ...] 20)
  require(crosshairs nil t)

Why is that?  Shouldn't the `condition-case' cause the load error for
vline.el to be ignored, since it occurs as part of the loading of
crosshairs.el?

In GNU Emacs 25.2.1 (x86_64-w64-mingw32)
 of 2017-04-24 built on LAPHROAIG
Windowing system distributor 'Microsoft Corp.', version 6.1.7601
Configured using:
 'configure --without-dbus --without-compress-install 'CFLAGS=-O2
 -static -g3''





             reply	other threads:[~2017-08-16 20:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-16 20:11 Drew Adams [this message]
2017-08-16 21:59 ` bug#28113: 25.2; `ignore-errors' around `require' Noam Postavsky
2017-08-16 22:39   ` Drew Adams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=07193cef-cdb9-4f39-a44e-920cf072411b@default \
    --to=drew.adams@oracle.com \
    --cc=28113@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.