[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#31549: 25.3; bytecompile fails with eval-when-compile
From: |
Eli Zaretskii |
Subject: |
bug#31549: 25.3; bytecompile fails with eval-when-compile |
Date: |
Wed, 23 May 2018 18:08:57 +0300 |
> Resent-Sender: help-debbugs@gnu.org
> From: Noam Postavsky <npostavs@gmail.com>
> Date: Tue, 22 May 2018 19:33:03 -0400
> Cc: 31549@debbugs.gnu.org
>
> > (byte-compile `(eval-when-compile (list ,@(make-list 2047 0))))
> >
> > Evaluating the form above, emacs (with -Q option) reports
> > Error: Memory exhausted--use C-x s then exit and restart Emacs
> > in *Compile-Log* buffer.
> > The returned value of the form is t.
>
> The error is coming from exec_byte_code:
>
> if (MAX_ALLOCA / word_size <= XFASTINT (maxdepth))
> memory_full (SIZE_MAX);
You mean, in expansion of SAFE_ALLOCA_LISP_EXTRA?
> It's more like a Lisp stack overflow than a memory exhausted situation
> though, hardly calls for restarting Emacs. Perhaps the byte compiler
> should refuse to compile such a large expression?
How about simply signaling a special error instead of memory_full?
Something like
error ("Lisp stack overflow");
- bug#31549: 25.3; bytecompile fails with eval-when-compile, ynyaaa, 2018/05/22
- bug#31549: 25.3; bytecompile fails with eval-when-compile, Noam Postavsky, 2018/05/22
- bug#31549: 25.3; bytecompile fails with eval-when-compile,
Eli Zaretskii <=
- bug#31549: 25.3; bytecompile fails with eval-when-compile, Noam Postavsky, 2018/05/23
- bug#31549: 25.3; bytecompile fails with eval-when-compile, Eli Zaretskii, 2018/05/24
- bug#31549: 25.3; bytecompile fails with eval-when-compile, Noam Postavsky, 2018/05/24
- bug#31549: 25.3; bytecompile fails with eval-when-compile, Eli Zaretskii, 2018/05/25
- bug#31549: 25.3; bytecompile fails with eval-when-compile, Noam Postavsky, 2018/05/27
- bug#31549: 25.3; bytecompile fails with eval-when-compile, Eli Zaretskii, 2018/05/27