<feed xmlns='http://www.w3.org/2005/Atom'>
<title>emacs/test/src, branch fix/bug-21072</title>
<subtitle>Emacs is the extensible, customizable, self-documenting real-time display editor. 
</subtitle>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/'/>
<entry>
<title>Fix circular read syntax for records.</title>
<updated>2017-04-08T06:47:46+00:00</updated>
<author>
<name>Lars Brinkhoff</name>
</author>
<published>2017-04-08T05:07:32+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=4fbfd7ad53810153371a588a9bd1a69230f60dd5'/>
<id>4fbfd7ad53810153371a588a9bd1a69230f60dd5</id>
<content type='text'>
* lread.c (substitute_object_recurse): Work with records.

* lread-tests.el (lread-record-1): New test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* lread.c (substitute_object_recurse): Work with records.

* lread-tests.el (lread-record-1): New test.
</pre>
</div>
</content>
</entry>
<entry>
<title>Deprecate copy-record in favor of copy-sequence</title>
<updated>2017-04-08T01:54:40+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2017-04-08T01:54:40+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=a2b3fea957440b8358d3632a4a05e41dee964b5d'/>
<id>a2b3fea957440b8358d3632a4a05e41dee964b5d</id>
<content type='text'>
Since copy-sequence seems to be needed anyway for records, have it
work on records, and remove copy-record as being superfluous.
* doc/lispref/records.texi (Records, Record Functions):
* lisp/emacs-lisp/cl-macs.el (cl-defstruct):
* lisp/emacs-lisp/eieio.el (make-instance, clone):
* test/src/alloc-tests.el (record-3):
Use copy-sequence, not copy-record, to copy records.
* doc/lispref/sequences.texi (Sequence Functions)
(Array Functions): Document that aref and copy-sequence
work on records.
* etc/NEWS: Omit copy-record.
* src/alloc.c (Fcopy_record): Remove.
* src/data.c (Faref): Document that arg can be a record.
* src/fns.c (Fcopy_sequence): Copy records, too.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Since copy-sequence seems to be needed anyway for records, have it
work on records, and remove copy-record as being superfluous.
* doc/lispref/records.texi (Records, Record Functions):
* lisp/emacs-lisp/cl-macs.el (cl-defstruct):
* lisp/emacs-lisp/eieio.el (make-instance, clone):
* test/src/alloc-tests.el (record-3):
Use copy-sequence, not copy-record, to copy records.
* doc/lispref/sequences.texi (Sequence Functions)
(Array Functions): Document that aref and copy-sequence
work on records.
* etc/NEWS: Omit copy-record.
* src/alloc.c (Fcopy_record): Remove.
* src/data.c (Faref): Document that arg can be a record.
* src/fns.c (Fcopy_sequence): Copy records, too.
</pre>
</div>
</content>
</entry>
<entry>
<title>Implement special sigma casing rule  (bug#24603)</title>
<updated>2017-04-06T18:54:58+00:00</updated>
<author>
<name>Michal Nazarewicz</name>
</author>
<published>2016-09-18T22:52:47+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=c1fa07222e9c76964d1261c31b50f1e399554fa2'/>
<id>c1fa07222e9c76964d1261c31b50f1e399554fa2</id>
<content type='text'>
In Greek, a sigma character has two lower case forms which depend on
their position in the word.  Implement logic determining it.

* src/casefiddle.c (struct casing_context, case_character_impl): Don’t
assume inword is true when flag is CASE_UP and false when flag is
CASE_DOWN.  For final sigma detection we need this information tracked
reliably;.
(CAPITAL_SIGMA, SMALL_SIGMA, SMALL_FINAL_SIGMA): New macros defining
Unicode code point of different forms of sigma letter.
(case_character): Implement support for final sigma casing.
(do_casify_multibyte_string, do_casify_multibyte_region): Update after
changes to case_character.

* test/src/casefiddle-tests.el (casefiddle-tests-casing): Add test
cases for final sigma.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In Greek, a sigma character has two lower case forms which depend on
their position in the word.  Implement logic determining it.

* src/casefiddle.c (struct casing_context, case_character_impl): Don’t
assume inword is true when flag is CASE_UP and false when flag is
CASE_DOWN.  For final sigma detection we need this information tracked
reliably;.
(CAPITAL_SIGMA, SMALL_SIGMA, SMALL_FINAL_SIGMA): New macros defining
Unicode code point of different forms of sigma letter.
(case_character): Implement support for final sigma casing.
(do_casify_multibyte_string, do_casify_multibyte_region): Update after
changes to case_character.

* test/src/casefiddle-tests.el (casefiddle-tests-casing): Add test
cases for final sigma.
</pre>
</div>
</content>
</entry>
<entry>
<title>Support casing characters which map into multiple code points  (bug#24603)</title>
<updated>2017-04-06T18:54:58+00:00</updated>
<author>
<name>Michal Nazarewicz</name>
</author>
<published>2016-10-04T22:06:01+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=b3b9b258c4026baa1cad3f2e617f1a637fc8d205'/>
<id>b3b9b258c4026baa1cad3f2e617f1a637fc8d205</id>
<content type='text'>
Implement unconditional special casing rules defined in Unicode standard.

Among other things, they deal with cases when a single code point is
replaced by multiple ones because single character does not exist (e.g.
‘ﬁ’ ligature turning into ‘FL’) or is not commonly used (e.g. ß turning
into SS).

* admin/unidata/SpecialCasing.txt: New data file pulled from Unicode
standard distribution.
* admin/unidata/README: Mention SpecialCasing.txt.

* admin/unidata/unidata-get.el (unidata-gen-table-special-casing,
unidata-gen-table-special-casing--do-load): New functions generating
‘special-uppercase’, ‘special-lowercase’ and ‘special-titlecase’
character Unicode properties built from the SpecialCasing.txt Unicode
data file.

* src/casefiddle.c (struct casing_str_buf): New structure for
representing short strings used to handle one-to-many character
mappings.

(case_character_imlp): New function which can handle one-to-many
character mappings.
(case_character, case_single_character): Wrappers for the above
functions.  The former may map one character to multiple (or no)
code points while the latter does what the former used to do (i.e.
handles one-to-one mappings only).

(do_casify_natnum, do_casify_unibyte_string,
do_casify_unibyte_region): Use case_single_character.
(do_casify_multibyte_string, do_casify_multibyte_region): Support new
features of case_character.
* (do_casify_region): Updated to reflact do_casify_multibyte_string
changes.

(casify_word): Handle situation when one character-length of a word
can change affecting where end of the word is.

(upcase, capitalize, upcase-initials): Update documentation to mention
limitations when working on characters.

* test/src/casefiddle-tests.el (casefiddle-tests-char-properties):
Add test cases for the newly introduced character properties.
(casefiddle-tests-casing): Update test cases which are now passing.

* test/lisp/char-fold-tests.el (char-fold--ascii-upcase,
char-fold--ascii-downcase): New functions which behave like old ‘upcase’
and ‘downcase’.
(char-fold--test-match-exactly): Use the new functions.  This is needed
because otherwise ﬁ and similar characters are turned into their multi-
-character representation.

* doc/lispref/strings.texi: Describe issue with casing characters versus
strings.
* doc/lispref/nonascii.texi: Describe the new character properties.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Implement unconditional special casing rules defined in Unicode standard.

Among other things, they deal with cases when a single code point is
replaced by multiple ones because single character does not exist (e.g.
‘ﬁ’ ligature turning into ‘FL’) or is not commonly used (e.g. ß turning
into SS).

* admin/unidata/SpecialCasing.txt: New data file pulled from Unicode
standard distribution.
* admin/unidata/README: Mention SpecialCasing.txt.

* admin/unidata/unidata-get.el (unidata-gen-table-special-casing,
unidata-gen-table-special-casing--do-load): New functions generating
‘special-uppercase’, ‘special-lowercase’ and ‘special-titlecase’
character Unicode properties built from the SpecialCasing.txt Unicode
data file.

* src/casefiddle.c (struct casing_str_buf): New structure for
representing short strings used to handle one-to-many character
mappings.

(case_character_imlp): New function which can handle one-to-many
character mappings.
(case_character, case_single_character): Wrappers for the above
functions.  The former may map one character to multiple (or no)
code points while the latter does what the former used to do (i.e.
handles one-to-one mappings only).

(do_casify_natnum, do_casify_unibyte_string,
do_casify_unibyte_region): Use case_single_character.
(do_casify_multibyte_string, do_casify_multibyte_region): Support new
features of case_character.
* (do_casify_region): Updated to reflact do_casify_multibyte_string
changes.

(casify_word): Handle situation when one character-length of a word
can change affecting where end of the word is.

(upcase, capitalize, upcase-initials): Update documentation to mention
limitations when working on characters.

* test/src/casefiddle-tests.el (casefiddle-tests-char-properties):
Add test cases for the newly introduced character properties.
(casefiddle-tests-casing): Update test cases which are now passing.

* test/lisp/char-fold-tests.el (char-fold--ascii-upcase,
char-fold--ascii-downcase): New functions which behave like old ‘upcase’
and ‘downcase’.
(char-fold--test-match-exactly): Use the new functions.  This is needed
because otherwise ﬁ and similar characters are turned into their multi-
-character representation.

* doc/lispref/strings.texi: Describe issue with casing characters versus
strings.
* doc/lispref/nonascii.texi: Describe the new character properties.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add support for title-casing letters  (bug#24603)</title>
<updated>2017-04-06T18:54:57+00:00</updated>
<author>
<name>Michal Nazarewicz</name>
</author>
<published>2016-08-11T23:38:49+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=13d813b1a093e9039a63b11021a8a92c9c5950d1'/>
<id>13d813b1a093e9039a63b11021a8a92c9c5950d1</id>
<content type='text'>
* src/casefiddle.c (struct casing_context, prepare_casing_context): Add
titlecase_char_table member.  It’s set to the ‘titlecase’ Unicode
property table if capitalisation has been requested.
(case_character): Make use of the titlecase_char_table to title-case
initial characters when capitalising.

* test/src/casefiddle-tests.el (casefiddle-tests--characters,
casefiddle-tests-casing): Update test cases which are now passing.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/casefiddle.c (struct casing_context, prepare_casing_context): Add
titlecase_char_table member.  It’s set to the ‘titlecase’ Unicode
property table if capitalisation has been requested.
(case_character): Make use of the titlecase_char_table to title-case
initial characters when capitalising.

* test/src/casefiddle-tests.el (casefiddle-tests--characters,
casefiddle-tests-casing): Update test cases which are now passing.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add record objects with user-defined types.</title>
<updated>2017-04-04T06:23:46+00:00</updated>
<author>
<name>Lars Brinkhoff</name>
</author>
<published>2013-01-06T13:27:44+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=a2c33430292c79ac520100b1d0e8e7c04dfe426a'/>
<id>a2c33430292c79ac520100b1d0e8e7c04dfe426a</id>
<content type='text'>
* src/alloc.c (allocate_record): New function.
(Fmake_record, Frecord, Fcopy_record): New functions.
(syms_of_alloc): defsubr them.
(purecopy): Work with records.

* src/data.c (Ftype_of): Return slot 0 for record objects, or type
name if record's type holds class.
(Frecordp): New function.
(syms_of_data): defsubr it.  Define `Qrecordp'.
(Faref, Faset): Work with records.

* src/fns.c (Flength): Work with records.

* src/lisp.h (prec_type): Add PVEC_RECORD.
(RECORDP, CHECK_RECORD, CHECK_RECORD_TYPE): New functions.

* src/lread.c (read1): Add syntax for records.

* src/print.c (PRINT_CIRCLE_CANDIDATE_P): Add RECORDP.
(print_object): Add syntax for records.

* test/lisp/emacs-lisp/cl-print-tests.el (cl-print-tests-2):
New test.

* test/src/alloc-tests.el (record-1, record-2, record-3):
New tests.

* doc/lispref/elisp.texi, doc/lispref/objects.texi,
doc/lispref/records.texi: Add documentation for records.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* src/alloc.c (allocate_record): New function.
(Fmake_record, Frecord, Fcopy_record): New functions.
(syms_of_alloc): defsubr them.
(purecopy): Work with records.

* src/data.c (Ftype_of): Return slot 0 for record objects, or type
name if record's type holds class.
(Frecordp): New function.
(syms_of_data): defsubr it.  Define `Qrecordp'.
(Faref, Faset): Work with records.

* src/fns.c (Flength): Work with records.

* src/lisp.h (prec_type): Add PVEC_RECORD.
(RECORDP, CHECK_RECORD, CHECK_RECORD_TYPE): New functions.

* src/lread.c (read1): Add syntax for records.

* src/print.c (PRINT_CIRCLE_CANDIDATE_P): Add RECORDP.
(print_object): Add syntax for records.

* test/lisp/emacs-lisp/cl-print-tests.el (cl-print-tests-2):
New test.

* test/src/alloc-tests.el (record-1, record-2, record-3):
New tests.

* doc/lispref/elisp.texi, doc/lispref/objects.texi,
doc/lispref/records.texi: Add documentation for records.
</pre>
</div>
</content>
</entry>
<entry>
<title>Some inotify cleanup</title>
<updated>2017-03-30T18:08:42+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2017-03-30T18:08:23+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=6ff870218dd4bc015cc4115ceb2febd8d807e57c'/>
<id>6ff870218dd4bc015cc4115ceb2febd8d807e57c</id>
<content type='text'>
This catches some problems with integer overflow and races
that I noticed in inotify.c after reviewing the changes
installed to fix Bug#26126.
* src/fns.c, src/lisp.h (equal_no_quit): Now extern.
* src/inotify.c (aspect_to_inotifymask):
Check for cycles and for improper lists.
(make_lispy_mask, lispy_mask_match_p): Remove.
All callers changed to use INTEGER_TO_CONS and CONS_TO_INTEGER.
(inotifyevent_to_event, add_watch):
Don’t assume watch descriptors and cookies fit in fixnums.
(add_watch): Use assoc_no_quit, not Fassoc.
Avoid integer overflow in (very!) long-running processes where
the Emacs watch ID could overflow.  Avoid some duplicate code.
(find_descriptor): New function.
(remove_descriptor): First arg is now the returned value from
find_descriptor, rather than the descriptor.  This way, the
value can be removed without calling Fdelete, which might quit.
Wait until the end (when watch_list is consistent) before signaling
any errors.
(remove_watch, inotify_callback):
Use find_descriptor to avoid the need for Fdelete.
(inotify_callback): Use simpler tests for ioctl failure.
Free temporary buffer if signaled, and put it on the stack if small.
Use ssize_t to index through read results, to avoid a cast.
(valid_watch_descriptor): New function, with a tighter check.
(Finotify_rm_watch, Finotify_valid_p): Use it.
(Finotify_valid_p): Use assoc_no_quit and ass_no_quit instead
of Fassoc.  Do not assume the first assoc succeeds.
* test/src/inotify-tests.el (inotify-valid-p-simple):
Add inotify-valid-p tests, some of which dump core without
the fixes noted above.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This catches some problems with integer overflow and races
that I noticed in inotify.c after reviewing the changes
installed to fix Bug#26126.
* src/fns.c, src/lisp.h (equal_no_quit): Now extern.
* src/inotify.c (aspect_to_inotifymask):
Check for cycles and for improper lists.
(make_lispy_mask, lispy_mask_match_p): Remove.
All callers changed to use INTEGER_TO_CONS and CONS_TO_INTEGER.
(inotifyevent_to_event, add_watch):
Don’t assume watch descriptors and cookies fit in fixnums.
(add_watch): Use assoc_no_quit, not Fassoc.
Avoid integer overflow in (very!) long-running processes where
the Emacs watch ID could overflow.  Avoid some duplicate code.
(find_descriptor): New function.
(remove_descriptor): First arg is now the returned value from
find_descriptor, rather than the descriptor.  This way, the
value can be removed without calling Fdelete, which might quit.
Wait until the end (when watch_list is consistent) before signaling
any errors.
(remove_watch, inotify_callback):
Use find_descriptor to avoid the need for Fdelete.
(inotify_callback): Use simpler tests for ioctl failure.
Free temporary buffer if signaled, and put it on the stack if small.
Use ssize_t to index through read results, to avoid a cast.
(valid_watch_descriptor): New function, with a tighter check.
(Finotify_rm_watch, Finotify_valid_p): Use it.
(Finotify_valid_p): Use assoc_no_quit and ass_no_quit instead
of Fassoc.  Do not assume the first assoc succeeds.
* test/src/inotify-tests.el (inotify-valid-p-simple):
Add inotify-valid-p tests, some of which dump core without
the fixes noted above.
</pre>
</div>
</content>
</entry>
<entry>
<title>min and max should not return markers</title>
<updated>2017-03-08T05:23:47+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2017-03-08T05:23:08+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=1590127335cef06af8d77884f9c16a8629d65943'/>
<id>1590127335cef06af8d77884f9c16a8629d65943</id>
<content type='text'>
Problem reported by Glenn Morris in:
http://lists.gnu.org/archive/html/emacs-devel/2017-03/msg00147.html
* src/data.c (minmax_driver): Convert any marker result to an
integer, since some callers assume this.
* test/src/data-tests.el (data-tests-max, data-tests-min):
Test for this.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Problem reported by Glenn Morris in:
http://lists.gnu.org/archive/html/emacs-devel/2017-03/msg00147.html
* src/data.c (minmax_driver): Convert any marker result to an
integer, since some callers assume this.
* test/src/data-tests.el (data-tests-max, data-tests-min):
Test for this.
</pre>
</div>
</content>
</entry>
<entry>
<title>min and max now return one of their arguments</title>
<updated>2017-03-07T01:26:55+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2017-03-06T23:14:32+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=37940b347052418f0589bd52b06e56fffb594ea2'/>
<id>37940b347052418f0589bd52b06e56fffb594ea2</id>
<content type='text'>
* doc/lispref/numbers.texi (Comparison of Numbers):
* etc/NEWS: Document this.
* src/data.c (Amax, Amin): Remove constants.  All uses removed.
(minmax_driver): New function.
(Fmax, Fmin): Use it instead of arith_driver.
* test/src/data-tests.el (data-tests-max, data-tests-min): New tests.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* doc/lispref/numbers.texi (Comparison of Numbers):
* etc/NEWS: Document this.
* src/data.c (Amax, Amin): Remove constants.  All uses removed.
(minmax_driver): New function.
(Fmax, Fmin): Use it instead of arith_driver.
* test/src/data-tests.el (data-tests-max, data-tests-min): New tests.
</pre>
</div>
</content>
</entry>
<entry>
<title>ffloor etc. now accept only floats</title>
<updated>2017-03-05T21:31:33+00:00</updated>
<author>
<name>Paul Eggert</name>
</author>
<published>2017-03-05T21:29:28+00:00</published>
<link rel='alternate' type='text/html' href='https://jason.zzq.org/git/emacs/commit/?id=53f3dd66f12660a47018fc03d50d460787ab6f64'/>
<id>53f3dd66f12660a47018fc03d50d460787ab6f64</id>
<content type='text'>
* etc/NEWS: Say why.
* src/floatfns.c (Ffceiling, Fffloor, Ffround, Fftruncate):
Require arg to be float.
* test/src/floatfns-tests.el (fround-fixnum): Check this.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* etc/NEWS: Say why.
* src/floatfns.c (Ffceiling, Fffloor, Ffround, Fftruncate):
Require arg to be float.
* test/src/floatfns-tests.el (fround-fixnum): Check this.
</pre>
</div>
</content>
</entry>
</feed>
