From: Eli Zaretskii <eliz@gnu.org>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: juanjose.garciaripoll@gmail.com, emacs-devel@gnu.org
Subject: Re: Interest in nt_load_image?
Date: Tue, 31 Mar 2020 17:19:44 +0300 [thread overview]
Message-ID: <83o8sc1u9r.fsf@gnu.org> (raw)
In-Reply-To: <jwvy2rhmyir.fsf-monnier+emacs@gnu.org> (message from Stefan Monnier on Mon, 30 Mar 2020 15:39:11 -0400)
> From: Stefan Monnier <monnier@iro.umontreal.ca>
> Cc: juanjose.garciaripoll@gmail.com, emacs-devel@gnu.org
> Date: Mon, 30 Mar 2020 15:39:11 -0400
>
> I suggest we write the code under the assumption that GDI+ is available
> and that's it.
I'd like to have a Lisp knob to select whether GDI+ or the various
image libraries are used for image handling, so the for systems
without GDI+ comes at almost no cost: just determine at startup what
is/are the value(s) of those variable(s).
> > There are no consequences. The paradigm of loading a shared library
> > dynamically and testing whether doing that succeeded is so boilerplate
> > in the w32 code that it never takes more than a simple copy/pasta to
> > add one more.
>
> But what do we do if the loading fails? If we simply fail to display
> the image, then that's fine by me. If OTOH we go through the trouble of
> falling back on some other code which otherwise wouldn't be needed in
> the build (and would hence never be tested, BTW), then it sounds like
> "waste precious resources".
If the library cannot be loaded, or doesn't have all the required
functions, the corresponding feature becomes unavailable, and we will
generally display an error message. This is clearly visible in the
code: that's what those FOO-available-p functions are there for. In
some rare cases, where we already have a fallback, we use it instead.
But those cases are a small minority.
> >> > One day it will die of natural causes, no need to invest even
> >> > a minimal effort in that.
> >> I'm not sure how that would happen
> > It will happen when 32-bit builds will die. 2038 at the latest.
>
> Are we sure sure 32bit Windows installations will have all disappeared
> by 2038 ? ;-)
Yes, I'm sure. In any case, Emacs will not be able to run on them, as
we use time functions all over the place.
next prev parent reply other threads:[~2020-03-31 14:19 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-29 19:33 Interest in nt_load_image? Juan José García-Ripoll
2020-03-29 21:55 ` Juan José García-Ripoll
2020-03-30 2:21 ` Eli Zaretskii
2020-03-30 7:54 ` Juan José García-Ripoll
2020-03-30 13:46 ` Eli Zaretskii
2020-03-30 14:36 ` Juan José García-Ripoll
2020-03-30 14:44 ` Juan José García-Ripoll
2020-03-30 15:50 ` Eli Zaretskii
2020-03-30 16:15 ` Juan José García-Ripoll
2020-03-30 16:37 ` Eli Zaretskii
2020-03-30 17:16 ` Stefan Monnier
2020-03-30 18:32 ` Eli Zaretskii
2020-03-30 18:41 ` Stefan Monnier
2020-03-30 18:57 ` Eli Zaretskii
2020-03-30 19:39 ` Stefan Monnier
2020-03-31 14:19 ` Eli Zaretskii [this message]
2020-03-30 18:06 ` Juan José García-Ripoll
2020-03-30 18:47 ` Eli Zaretskii
2020-03-30 18:53 ` Eli Zaretskii
2020-03-30 23:21 ` Juanma Barranquero
2020-03-31 8:01 ` Juan José García-Ripoll
2020-03-31 13:14 ` Juanma Barranquero
2020-03-31 14:50 ` Stefan Monnier
2020-03-31 15:25 ` Juanma Barranquero
2020-03-31 16:54 ` Stefan Monnier
2020-03-31 15:13 ` Juan José García-Ripoll
2020-03-31 15:28 ` Juanma Barranquero
2020-03-31 13:31 ` Eli Zaretskii
2020-03-30 15:14 ` Stefan Monnier
2020-03-30 15:57 ` Eli Zaretskii
2020-03-30 17:10 ` Stefan Monnier
2020-03-30 18:23 ` Eli Zaretskii
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83o8sc1u9r.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=juanjose.garciaripoll@gmail.com \
--cc=monnier@iro.umontreal.ca \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).