From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.help Subject: Re: Flycheck reports are never satisfying!? Date: Thu, 28 Aug 2014 23:32:10 -0400 Organization: A noiseless patient Spider Message-ID: References: <86ha0w95vp.fsf@somewhere.org> <86a96oikkx.fsf@somewhere.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1409283328 29972 80.91.229.3 (29 Aug 2014 03:35:28 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 29 Aug 2014 03:35:28 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Aug 29 05:35:18 2014 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XNCy5-0004ma-Ck for geh-help-gnu-emacs@m.gmane.org; Fri, 29 Aug 2014 05:35:17 +0200 Original-Received: from localhost ([::1]:39954 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XNCy4-0005MU-QN for geh-help-gnu-emacs@m.gmane.org; Thu, 28 Aug 2014 23:35:16 -0400 Original-Path: usenet.stanford.edu!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed.xs4all.nl!newsfeed1.news.xs4all.nl!xs4all!news.stack.nl!eternal-september.org!feeder.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 40 Injection-Info: mx05.eternal-september.org; posting-host="4a1b74b6c0390da37c3a9b2bf2984cd9"; logging-data="777"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/KYThW+bexOlTQ307zZvoq" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4.50 (gnu/linux) Cancel-Lock: sha1:6bPefZ/FTXmPYp2xymSun7zoHYc= sha1:lR9DidMafQPrFSfqPDZAzGmDgiE= Original-Xref: usenet.stanford.edu gnu.emacs.help:207217 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:99494 Archived-At: > That would make a lot of sense, IMHO. I could consider inclusion of such a patch. > --8<---------------cut here---------------start------------->8--- > (when (try-require 'blah) > ...) > --8<---------------cut here---------------end--------------->8--- > Would there be a solution? No, the compiler doesn't know anything about try-require. > Would replacing `try-require' by a `require' with all the necessary > parameters (in order not to stop if the package is missing) be OK? > --8<---------------cut here---------------start------------->8--- > (when (require 'blah nil t) > ...) > --8<---------------cut here---------------end--------------->8--- > Would this last construct work? If yes, I'm willing to use it instead > of my `try-require'... Maybe we could make it work, yes. Still, there's a problem: one of the reasons to try and byte-compile the .emacs file is so as to give warnings to the user about use of obsolete variables and functions. But for that to work well (i.e. used all the time by default), byte-compilation should be quick and lightweight. But that won't work if we start pre-loading eagerly all those packages that the user is painstaking trying to load lazily. I have this nagging feeling that we can't make it work by just byte-compiling the .emacs in the same way as any other Elisp package. Maybe rather than re-using the byte-compiler's warnings, we really need a specialized tool for that. Stefan