Mercurial > hg > xemacs-beta
annotate src/m/arm.h @ 5307:c096d8051f89
Have NATNUMP give t for positive bignums; check limits appropriately.
src/ChangeLog addition:
2010-11-20 Aidan Kehoe <kehoea@parhasard.net>
* abbrev.c (Fexpand_abbrev):
* alloc.c:
* alloc.c (Fmake_list):
* alloc.c (Fmake_vector):
* alloc.c (Fmake_bit_vector):
* alloc.c (Fmake_byte_code):
* alloc.c (Fmake_string):
* alloc.c (vars_of_alloc):
* bytecode.c (UNUSED):
* bytecode.c (Fbyte_code):
* chartab.c (decode_char_table_range):
* cmds.c (Fself_insert_command):
* data.c (check_integer_range):
* data.c (Fnatnump):
* data.c (Fnonnegativep):
* data.c (Fstring_to_number):
* elhash.c (hash_table_size_validate):
* elhash.c (decode_hash_table_size):
* eval.c (Fbacktrace_frame):
* event-stream.c (lisp_number_to_milliseconds):
* event-stream.c (Faccept_process_output):
* event-stream.c (Frecent_keys):
* event-stream.c (Fdispatch_event):
* events.c (Fmake_event):
* events.c (Fevent_timestamp):
* events.c (Fevent_timestamp_lessp):
* events.h:
* events.h (struct command_builder):
* file-coding.c (gzip_putprop):
* fns.c:
* fns.c (check_sequence_range):
* fns.c (Frandom):
* fns.c (Fnthcdr):
* fns.c (Flast):
* fns.c (Fnbutlast):
* fns.c (Fbutlast):
* fns.c (Fmember):
* fns.c (Ffill):
* fns.c (Freduce):
* fns.c (replace_string_range_1):
* fns.c (Freplace):
* font-mgr.c (Ffc_pattern_get):
* frame-msw.c (msprinter_set_frame_properties):
* glyphs.c (check_valid_xbm_inline):
* indent.c (Fmove_to_column):
* intl-win32.c (mswindows_multibyte_to_unicode_putprop):
* lisp.h:
* lisp.h (ARRAY_DIMENSION_LIMIT):
* lread.c (decode_mode_1):
* mule-ccl.c (ccl_get_compiled_code):
* number.h:
* process-unix.c (unix_open_multicast_group):
* process.c (Fset_process_window_size):
* profile.c (Fstart_profiling):
* unicode.c (Funicode_to_char):
Change NATNUMP to return 1 for positive bignums; changes uses of
it and of CHECK_NATNUM appropriately, usually by checking for an
integer in an appropriate range.
Add array-dimension-limit and use it in #'make-vector,
#'make-string. Add array-total-size-limit, array-rank-limit while
we're at it, for the sake of any Common Lisp-oriented code that
uses these limits.
Rename check_int_range to check_integer_range, have it take
Lisp_Objects (and thus bignums) instead.
Remove bignum_butlast(), just set int_n to an appropriately large
integer if N is a bignum.
Accept bignums in check_sequence_range(), change the functions
that use check_sequence_range() appropriately.
Move the definition of NATNUMP() to number.h; document why it's a
reasonable name, contradicting an old comment.
tests/ChangeLog addition:
2010-11-20 Aidan Kehoe <kehoea@parhasard.net>
* automated/lisp-tests.el:
* automated/lisp-tests.el (featurep):
* automated/lisp-tests.el (wrong-type-argument):
* automated/mule-tests.el (featurep):
Check for args-out-of-range errors instead of wrong-type-argument
errors in various places when code is handed a large bignum
instead of a fixnum.
Also check for the wrong-type-argument errors when giving the same
code a non-integer value.
author | Aidan Kehoe <kehoea@parhasard.net> |
---|---|
date | Sat, 20 Nov 2010 16:49:11 +0000 |
parents | aa5ed11f473b |
children | 308d34e9f07d 861f2601a38b |
rev | line source |
---|---|
321 | 1 /* Machine description file for digital/intel arm/strongarm |
2 Copyright (C) 1987 Free Software Foundation, Inc. | |
3 | |
4 This file is part of GNU Emacs. | |
5 | |
6 GNU Emacs is free software; you can redistribute it and/or modify | |
7 it under the terms of the GNU General Public License as published by | |
8 the Free Software Foundation; either version 2, or (at your option) | |
9 any later version. | |
10 | |
11 GNU Emacs is distributed in the hope that it will be useful, | |
12 but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 GNU General Public License for more details. | |
15 | |
16 You should have received a copy of the GNU General Public License | |
17 along with XEmacs; see the file COPYING. If not, write to | |
18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | |
19 Boston, MA 02111-1307, USA. */ | |
20 | |
21 /* Synched up with: FSF 19.31. */ | |
22 | |
23 /* Now define a symbol for the cpu type, if your compiler | |
24 does not define it automatically: | |
25 Ones defined so far include vax, m68000, ns16000, pyramid, | |
26 orion, tahoe, APOLLO and many others */ | |
27 | |
28 #ifndef arm | |
29 #define arm | |
30 #endif | |
31 | |
32 /* crt0.c, if it is used, should use the i386-bsd style of entry. | |
4759
aa5ed11f473b
Remove support for obsolete systems. See xemacs-patches message with ID
Jerry James <james@xemacs.org>
parents:
1330
diff
changeset
|
33 with no extra dummy args. On USG, NO_REMAP says this isn't used. */ |
321 | 34 |
35 /* Mly 16-Jan-96 16:38:32: this is part of a prototype -- same bug present in | |
36 other m*.h files */ | |
37 #define CRT0_DUMMIES int bogus_fp, | |
38 | |
39 /* crt0.c should define a symbol `start' and do .globl with a dot. */ | |
40 | |
41 #define DOT_GLOBAL_START | |
42 | |
43 #ifdef USG5_4 /* Older USG systems do not support the load average. */ | |
44 /* Data type of load average, as read out of kmem. */ | |
45 | |
46 #define LOAD_AVE_TYPE long | |
47 | |
48 /* Convert that into an integer that is 100 for a load average of 1.0 */ | |
49 /* This is totally uncalibrated. */ | |
50 | |
51 | |
52 /* FSHIFT and FSCALE are defined in param.h, but are required by | |
53 LOAD_AVE_CVT, so they need to be defined here. */ | |
54 | |
55 #ifndef FSHIFT | |
56 #define FSHIFT 8 /* bits to right of fixed binary point */ | |
57 #endif | |
58 | |
59 #ifndef FSCALE | |
60 #define FSCALE (1<<FSHIFT) | |
61 #endif | |
62 | |
63 #define LOAD_AVE_CVT(x) ((int) (((double) (x)) * 100.0 / FSCALE)) | |
64 #endif | |
65 | |
66 | |
67 /* this brings in alloca() if we're using cc */ | |
68 #ifdef USG | |
69 #define NO_REMAP | |
70 #define TEXT_START 0 | |
71 #endif /* USG */ | |
72 | |
442 | 73 #ifdef WIN32_NATIVE |
321 | 74 #define DATA_START get_data_start () |
75 #endif | |
76 | |
77 #ifdef linux | |
78 /* libc-linux/sysdeps/linux/i386/ulimit.c says that due to shared library, */ | |
79 /* we cannot get the maximum address for brk */ | |
80 #define ULIMIT_BREAK_VALUE (32*1024*1024) | |
81 | |
82 #define SEGMENT_MASK ((SEGMENT_SIZE)-1) | |
83 #endif |