aboutsummaryrefslogtreecommitdiffstats
path: root/src/regex.h
Commit message (Collapse)AuthorAgeFilesLines
* Update copyright year to 2014 by running admin/update-copyright.Paul Eggert2014-01-011-1/+1
|
* Prefer 'unsigned long' to 'long unsigned int' and 'unsigned long int'.Dmitry Antipov2013-10-291-1/+1
| | | | | | | | | | | | | | * ftxfont.c (ftxfont_get_gcs): * gtkutil.c (xg_set_widget_bg, xg_set_background_color): * xfaces.c (x_free_colors, x_free_dpy_colors) (x_create_gc, unload_color): * xselect.c (x_property_data_to_lisp): * xsettings.c (parse_settings): * xterm.c (x_copy_color, x_alloc_lighter_color, x_setup_relief_color) (get_bits_and_offset): Adjust definition. * frame.c (XParseGeometry): Adjust locals. * lisp.h (toplevel): Adjust EMACS_UINT type definition. * regex.h (toplevel): Likewise for reg_syntax_t.
* Port to C89.Paul Eggert2013-07-101-18/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lib-src/ebrowse.c (USAGE): Remove macro with too-long string literal ... (usage_message): ... and replace it with this new static constant containing multiple literals. All uses changed. * lib-src/emacsclient.c (print_help_and_exit): Rewrite to avoid string literals longer than the C89 limits. (start_daemon_and_retry_set_socket): Rewrite to avoid non-constant array initializer. * lib-src/make-docfile.c (enum global_type): Omit trailing comma. * src/bytecode.c (BYTE_CODE_THREADED): Do not define if __STRICT_ANSI__. (B__dummy__): New dummy symbol, to pacify C89. * src/dbusbind.c (XD_DEBUG_MESSAGE): Omit debugging on C89 hosts, since they can't grok varargs macros. * src/dispnew.c (add_window_display_history) (add_frame_display_history): * src/print.c (print_object): * src/xdisp.c (debug_method_add): Use %p printf format only for void pointers. * src/emacs.c (usage_message): New constant, replacing ... (USAGE1, USAGE2, USAGE3): Remove; they were too long for C89. (main): Adjust to usage reorg. * src/fns.c (syms_of_fns): * src/profiler.c (syms_of_profiler): Don't use non-constant struct initializers. * src/gnutls.h (gnutls_initstage_t): * src/lisp.h (enum Lisp_Fwd_Type): * src/lread.c (lisp_file_lexically_bound_p): * src/xsettings.c (anonymous enum): Remove trailing comma. * src/xsettings.c (apply_xft_settings): Use %f, not %lf; %lf is a C99ism. * src/lisp.h (ENUM_BF): Use unsigned if pedantic. (DEFUN_FUNCTION_INIT): New macro, that falls back on a cast if pre-C99. (DEFUN): Use it. * src/regex.c (const_re_char): New type, to pacify strict C89. All uses of 'const re_char' replaced to use it. * src/regex.h (_Restrict_): Rename from __restrict, to avoid clash with glibc when strict C89. This change is imported from gnulib. All uses changed. (_Restrict_arr_): Rename from __restrict_arr, similarly. * src/sysdep.c (time_from_jiffies) [!HAVE_LONG_LONG_INT]: Omit GNU_LINUX implementation, since it requires long long. * src/xterm.c (x_draw_underwave): Do not assume the traditional order of struct's members. (x_term_init): Rewrite to avoid the need for non-constant structure initializers.
* Reorder conditions that are written backwardsAndreas Schwab2013-03-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * alloc.c (xpalloc, Fgarbage_collect): Reorder conditions that are written backwards. * blockinput.h (input_blocked_p): Likewise. * bytecode.c (exec_byte_code): Likewise. * callproc.c (call_process_kill, call_process_cleanup) (Fcall_process): Likewise. * ccl.c (ccl_driver, resolve_symbol_ccl_program) (Fccl_execute_on_string): Likewise. * character.c (string_escape_byte8): Likewise. * charset.c (read_hex): Likewise. * cm.c (calccost): Likewise. * data.c (cons_to_unsigned): Likewise. * dired.c (directory_files_internal, file_name_completion): Likewise. * dispnew.c (scrolling_window, update_frame_1, Fsleep_for) (sit_for): Likewise. * doc.c (Fsubstitute_command_keys): Likewise. * doprnt.c (doprnt): Likewise. * editfns.c (hi_time, decode_time_components, Fformat): Likewise. * emacsgtkfixed.c: Likewise. * fileio.c (file_offset, Fwrite_region): Likewise. * floatfns.c (Fexpt, fmod_float): Likewise. * fns.c (larger_vector, make_hash_table, Fmake_hash_table): Likewise. * font.c (font_intern_prop): Likewise. * frame.c (x_set_alpha): Likewise. * gtkutil.c (get_utf8_string): Likewise. * indent.c (check_display_width): Likewise. * intervals.c (create_root_interval, rotate_right, rotate_left) (split_interval_right, split_interval_left) (adjust_intervals_for_insertion, delete_node) (interval_deletion_adjustment, adjust_intervals_for_deletion) (merge_interval_right, merge_interval_left, copy_intervals) (set_intervals_multibyte_1): Likewise. * keyboard.c (gobble_input, append_tool_bar_item): Likewise. * keymap.c (Fkey_description): Likewise. * lisp.h (FIXNUM_OVERFLOW_P, vcopy): Likewise. * lread.c (openp, read_integer, read1, string_to_number): Likewise. * menu.c (ensure_menu_items): Likewise. * minibuf.c (read_minibuf_noninteractive): Likewise. * print.c (printchar, strout): Likewise. * process.c (create_process, Faccept_process_output) (wait_reading_process_output, read_process_output, send_process) (wait_reading_process_output): Likewise. * profiler.c (make_log, handle_profiler_signal): Likewise. * regex.c (re_exec): Likewise. * regex.h: Likewise. * search.c (looking_at_1, Freplace_match): Likewise. * sysdep.c (get_child_status, procfs_ttyname) (procfs_get_total_memory): Likewise. * systime.h (EMACS_TIME_VALID_P): Likewise. * term.c (dissociate_if_controlling_tty): Likewise. * window.c (get_phys_cursor_glyph): Likewise. * xdisp.c (init_iterator, redisplay_internal, redisplay_window) (try_window_reusing_current_matrix, try_window_id, pint2hrstr): Likewise. * xfns.c (Fx_window_property): Likewise. * xmenu.c (set_frame_menubar): Likewise. * xselect.c (x_get_window_property, x_handle_dnd_message): Likewise. * xsmfns.c (smc_save_yourself_CB): Likewise. * xterm.c (x_scroll_bar_set_handle): Likewise.
* Update copyright notices for 2013.Paul Eggert2013-01-011-2/+2
|
* Use URLs, not Boston addresses, in copyright notices.Paul Eggert2012-12-311-3/+1
|
* Assume C89 or later.Paul Eggert2012-05-211-53/+38
| | | | | | | | | | | | | | | | | | | * configure.in (AC_C_PROTOTYPES, AC_C_VOLATILE, AC_C_CONST) (POINTER_TYPE, PROTOTYPES): Remove. * admin/CPP-DEFINES: Remove NULL, const. * lib-src/etags.c (static, const): Remove macros. (PTR): Remove; all uses replaced with void *. Omit needless casts. * src/alloc.c, src/buffer.c, lisp.h: Replace POINTER_TYPE with void. * alloc.c (overrun_check_malloc, overrun_check_realloc, xmalloc) (xrealloc): * buffer.c (mmap_free_1, mmap_enlarge): Omit needless casts. * editfns.c, fns.c, gmalloc.c, insdel.c, sysdep.c, termcap.c (NULL): * textprop.c, tparam.c (NULL): Remove. * ralloc.c, vm-limit.c (POINTER): Assume void * works. * regex.c (SIGN_EXTEND_CHAR): Assume signed char works. * regex.h (_RE_ARGS): Remove. All uses rewritten to use prototypes. * unexelf.c (ElfBitsW): Assume c89 preprocessor or better. * xterm.c (input_signal_count): Assume volatile works.
* Add 2012 to FSF copyright years for Emacs filesGlenn Morris2012-01-051-1/+1
|
* Spelling fixes.Paul Eggert2011-12-051-2/+2
|
* Spelling fixes.Paul Eggert2011-11-141-1/+1
|
* Fix regex.c, syntax.c and friends for buffers > 2GB.Eli Zaretskii2011-04-161-20/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | src/syntax.h (struct gl_state_s): Declare character position members EMACS_INT. src/syntax.c (update_syntax_table): Declare 2nd argument EMACS_INT. src/textprop.c (verify_interval_modification, interval_of): Declare arguments EMACS_INT. src/intervals.c (adjust_intervals_for_insertion): Declare arguments EMACS_INT. src/intervals.h (CHECK_TOTAL_LENGTH): Cast to EMACS_INT, not `int'. src/indent.c (Fvertical_motion): Local variable it_start is now EMACS_INT. src/regex.c (re_match, re_match_2, re_match_2_internal) (bcmp_translate, regcomp, regexec, print_double_string) (group_in_compile_stack, re_search, re_search_2, regex_compile) (re_compile_pattern, re_exec): Declare arguments and local variables `size_t' and `ssize_t' and return values `regoff_t', as appropriate. (POP_FAILURE_REG_OR_COUNT) <pfreg>: Declare `long'. (CHECK_INFINITE_LOOP) <failure>: Declare `ssize_t'. <compile_stack_type>: `size' and `avail' are now `size_t'. src/regex.h <regoff_t>: Use ssize_t, not int. (re_search, re_search_2, re_match, re_match_2): Arguments that specify buffer/string position and length are now ssize_t and size_t. Return type is regoff_t.
* Convert consecutive FSF copyright years to ranges.Glenn Morris2011-01-241-2/+1
|
* Nuke arch-tags.Glenn Morris2011-01-151-2/+0
|
* Add 2011 to FSF/AIST copyright years.Glenn Morris2011-01-021-1/+1
|
* Add 2010 to copyright years.Glenn Morris2010-01-131-1/+1
|
* Add 2009 to copyright years.Glenn Morris2009-01-081-1/+1
|
* Update copyrights.Stefan Monnier2008-02-121-1/+1
|
* Merge from emacs--devo--0Miles Bader2007-07-271-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Patches applied: * emacs--devo--0 (patch 824-831) - Update from CVS - Merge from emacs--rel--22 * emacs--rel--22 (patch 70-74) - Update from CVS Revision: [email protected]/emacs--unicode--0--patch-238
* | (struct re_pattern_buffer): New meumber charset_unibyte.Kenichi Handa2007-02-151-3/+4
| |
* | Merge from emacs--devo--0Miles Bader2007-01-261-2/+3
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Patches applied: * emacs--devo--0 (patch 586-614) - Update from CVS - Update from erc--emacs--22 - Merge from gnus--rel--5.10 - Merge from erc--main--0 - Make byte compiler correctly write circular constants * gnus--rel--5.10 (patch 186-196) - Update from CVS - Merge from emacs--devo--0 Revision: [email protected]/emacs--unicode--0--patch-162
| * Update copyright for years from Emacs 21 to present (mainly addingGlenn Morris2007-01-141-2/+3
| | | | | | | | 2001).
* | Merge from emacs--devo--0Miles Bader2006-10-151-8/+4
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Patches applied: * emacs--devo--0 (patch 460-475) - Update from CVS - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 145-152) - Merge from emacs--devo--0 - Update from CVS Revision: [email protected]/emacs--unicode--0--patch-118
| * Remove file local variables.Stefan Monnier2006-10-031-8/+4
| | | | | | | | (struct re_pattern_buffer): New field `used_syntax'.
* | Revision: [email protected]/emacs--unicode--0--patch-13Miles Bader2006-02-081-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge from emacs--devo--0 Patches applied: * emacs--devo--0 (patch 43-57) - Update from CVS - Merge from erc--emacs--0 - Make constrain-to-field notice overlays - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 18-21) - Update from CVS - Merge from emacs--devo--0
| * Update years in copyright notice; nfc.Thien-Thi Nguyen2006-02-061-1/+1
| |
* | Revision: [email protected]/emacs--unicode--0--patch-88Miles Bader2005-10-071-0/+5
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge from emacs--cvs-trunk--0 Patches applied: * emacs--cvs-trunk--0 (patch 569-579) - Update from CVS - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 129-132) - Update from CVS - Merge from emacs--cvs-trunk--0
| * (re_char): Don't expose it in the interface.Stefan Monnier2005-10-041-4/+1
| | | | | | | | (re_set_whitespace_regexp): Adjust the arg's type to not use it.
| * * image.c (slurp_file, xbm_read_bitmap_data): Cast to the correctDan Nicolaescu2005-09-301-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | type. * xterm.c (handle_one_xevent, handle_one_xevent): Likewise. * unexelf.c (fatal): Fix prototype. * term.c (fatal): Implement using varargs. * regex.c (re_char): Move typedef ... * regex.h (re_char): ... here. (re_iswctype, re_wctype, re_set_whitespace_regexp): New prototypes. * emacs.c (malloc_set_state): Fix return type. (endif): Fix type. * lisp.h (fatal): Add argument types. * dispextern.h (fatal): Delete prototype. * systime.h: (make_time): Prototype moved from ... * editfns.c (make_time): ... here. * editfns.c: Move systime.h include after lisp.h. * dired.c: * xsmfns.c: * process.c: Likewise. * alloc.c (old_malloc_hook, old_realloc_hook, old_realloc_hook): Add parameter types. (__malloc_hook, __realloc_hook, __free_hook): Fix prototypes. (emacs_blocked_free): Change definition to match __free_hook. (emacs_blocked_malloc): Change definition to match __malloc_hook. (emacs_blocked_realloc): Change definition to match __realloc_hook.
* | Revision: [email protected]/emacs--unicode--0--patch-78Miles Bader2005-08-261-1/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge from emacs--cvs-trunk--0 Patches applied: * emacs--cvs-trunk--0 (patch 514-518) - Update from CVS - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 104-105) - Update from CVS
| * Update years in copyright notice; nfc.Thien-Thi Nguyen2005-08-071-1/+2
| |
* | Revision: [email protected]/emacs--unicode--0--patch-68Miles Bader2005-07-071-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge from emacs--cvs-trunk--0 Patches applied: * emacs--cvs-trunk--0 (patch 459-473) - Update from CVS - Merge from gnus--rel--5.10 * gnus--rel--5.10 (patch 86-87) - Update from CVS
| * Update FSF's address.Lute Kamstra2005-07-041-1/+1
| |
* | Revision: [email protected]/emacs--unicode--0--patch-65Miles Bader2004-10-271-1/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge from emacs--cvs-trunk--0 Patches applied: * [email protected]/emacs--cvs-trunk--0--patch-634 - [email protected]/emacs--cvs-trunk--0--patch-639 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-640 Merge from gnus--rel--5.10 * [email protected]/emacs--cvs-trunk--0--patch-641 Update from CVS * [email protected]/gnus--rel--5.10--patch-59 - [email protected]/gnus--rel--5.10--patch-60 Update from CVS
| * (enum reg_errcode_t): New value REG_ERANGEX.Kenichi Handa2004-10-241-1/+2
| |
* | Revision: [email protected]/emacs--unicode--0--patch-15Miles Bader2004-06-281-0/+43
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Merge from emacs--cvs-trunk--0 Patches applied: * [email protected]/emacs--cvs-trunk--0--patch-218 - [email protected]/emacs--cvs-trunk--0--patch-220 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-221 Restore deleted tagline in etc/TUTORIAL.ru * [email protected]/emacs--cvs-trunk--0--patch-222 - [email protected]/emacs--cvs-trunk--0--patch-228 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-229 Remove TeX output files from the archive * [email protected]/emacs--cvs-trunk--0--patch-230 - [email protected]/emacs--cvs-trunk--0--patch-247 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-248 src/lisp.h (CYCLE_CHECK): Macro moved from xfaces.c * [email protected]/emacs--cvs-trunk--0--patch-249 - [email protected]/emacs--cvs-trunk--0--patch-256 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-258 - [email protected]/emacs--cvs-trunk--0--patch-263 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-264 Update from CVS: lispref/display.texi: emacs -> Emacs. * [email protected]/emacs--cvs-trunk--0--patch-265 - [email protected]/emacs--cvs-trunk--0--patch-274 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-275 Update from CVS: man/makefile.w32-in: Revert last change * [email protected]/emacs--cvs-trunk--0--patch-276 - [email protected]/emacs--cvs-trunk--0--patch-295 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-296 Allow restarting an existing debugger session that's exited * [email protected]/emacs--cvs-trunk--0--patch-297 - [email protected]/emacs--cvs-trunk--0--patch-299 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-300 - [email protected]/emacs--cvs-trunk--0--patch-327 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-328 Update from CVS: src/.gdbinit (xsymbol): Fix last change. * [email protected]/emacs--cvs-trunk--0--patch-329 - [email protected]/emacs--cvs-trunk--0--patch-344 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-345 Tweak source regexps so that building in place won't cause problems * [email protected]/emacs--cvs-trunk--0--patch-346 - [email protected]/emacs--cvs-trunk--0--patch-351 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-352 Update from CVS: lisp/flymake.el: New file. * [email protected]/emacs--cvs-trunk--0--patch-353 - [email protected]/emacs--cvs-trunk--0--patch-361 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-362 Support " [...]" style defaults in minibuffer-electric-default-mode * [email protected]/emacs--cvs-trunk--0--patch-363 (read-number): Use canonical format for default in prompt. * [email protected]/emacs--cvs-trunk--0--patch-364 - [email protected]/emacs--cvs-trunk--0--patch-367 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-368 Improve display-supports-face-attributes-p on non-ttys * [email protected]/emacs--cvs-trunk--0--patch-369 Rewrite face-differs-from-default-p * [email protected]/emacs--cvs-trunk--0--patch-370 Move `display-supports-face-attributes-p' entirely into C code * [email protected]/emacs--cvs-trunk--0--patch-371 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-372 Simplify face-differs-from-default-p; don't consider :stipple. * [email protected]/emacs--cvs-trunk--0--patch-373 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-374 (tty_supports_face_attributes_p): Ensure attributes differ from default * [email protected]/emacs--cvs-trunk--0--patch-375 - [email protected]/emacs--cvs-trunk--0--patch-376 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-377 (Fdisplay_supports_face_attributes_p): Work around bootstrapping problem * [email protected]/emacs--cvs-trunk--0--patch-378 - [email protected]/emacs--cvs-trunk--0--patch-380 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-381 Face merging cleanups * [email protected]/emacs--cvs-trunk--0--patch-382 - [email protected]/emacs--cvs-trunk--0--patch-384 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-385 src/xfaces.c (push_named_merge_point): Return 0 if a cycle is detected * [email protected]/emacs--cvs-trunk--0--patch-386 - [email protected]/emacs--cvs-trunk--0--patch-395 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-396 Tweak arch tagging to make build/install-in-place less annoying * [email protected]/emacs--cvs-trunk--0--patch-397 Work around vc-arch problems when building eshell * [email protected]/emacs--cvs-trunk--0--patch-398 Tweak permissions * [email protected]/emacs--cvs-trunk--0--patch-399 Tweak directory permissions * [email protected]/emacs--cvs-trunk--0--patch-400 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-401 More build-in-place tweaking of arch tagging * [email protected]/emacs--cvs-trunk--0--patch-402 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-403 Yet more build-in-place tweaking of arch tagging * [email protected]/emacs--cvs-trunk--0--patch-404 - [email protected]/emacs--cvs-trunk--0--patch-409 Update from CVS * [email protected]/emacs--cvs-trunk--0--patch-410 Make sure image types are initialized for lookup too * [email protected]/emacs--cvs-trunk--0--patch-411 - [email protected]/emacs--cvs-trunk--0--patch-416 Update from CVS
| * (CHAR_CLASS_MAX_LENGTH, re_wctype_t, re_wchar_t)Richard M. Stallman2004-06-131-0/+43
| | | | | | | | | | (re_wctype, re_iswctype, re_wctype_to_bit): Non-function definitions moved here from regex.c.
* | Sync to HEAD.Kenichi Handa2004-04-081-0/+3
| |
* | *** empty log message ***Kenichi Handa2003-09-081-2/+8
|\ \
| * | (struct re_pattern_buffer): New member target_multibyte.Kenichi Handa2002-09-031-2/+6
| | |
* | | New directoryKenichi Handa2003-09-081-3/+0
| |/ |/|
* | Add arch taglinesMiles Bader2003-09-011-0/+3
| |
* | Comment and whitespace changes regarding # define __restrict_arrFrancesco Potortì2002-09-301-2/+2
| |
* | (__restrict_arr): Don't define if already defined.Richard M. Stallman2002-09-261-0/+2
|/
* Remove warning that noone noticed anywayJeff Bailey2000-10-171-4/+0
|
* Add warning to top of source filesJeff Bailey2000-09-191-0/+4
|
* * regex.h (RE_NO_NEWLINE_ANCHOR): New syntax flag.Stefan Monnier2000-08-311-3/+11
| | | | | | | | | | | | | (struct re_pattern_buffer): Remove newline_anchor. * regex.c: Keep namespace clean for GNU libc by renaming <fun> to __<fun> and using `weak_alias (__<fun>, <fun>)'. (re_max_failures, fail_stack): Use size_t rather than unsigned. (regex_compile): For ^ and $, choose between buffer and line (beg|end) depending on the new RE_NO_NEWLINE_ANCHOR syntax flag. (print_compiled_pattern, re_search_2, mutually_exclusive_p) (re_match_2_internal, re_compile_pattern, re_comp, regcomp): Get rid of references to newline_anchor. (regcomp): Allocate and precompute a fastmap.
* (struct re_pattern_buffer): Use size_t for used/allocated.Stefan Monnier2000-08-301-11/+3
|
* * regex.c: Indent cpp directives and remove parens after `defined'.Stefan Monnier2000-08-281-60/+116
| | | | | | | | | | (PTR_TO_OFFSET, POS_AS_IN_BUFFER): Move to a better place. (ISDIGIT, ISCNTRL, ISXDIGIT) [!emacs]: Remove duplicate definition. (regex_compile): Use RE_FRUGAL instead of RE_ALL_GREEDY. (re_compile_pattern): Use size_t for length. (init_syntax_once): Move to a better place. * regex.h: Merge changes from GNU libc. Indent cpp directives. (RE_FRUGAL): Replaces RE_ALL_GREEDY (inverted meaning).
* Test PROTOTYPES as well as __STDC__.Dave Love2000-06-191-3/+3
|
* * regex.c (PTR_TO_OFFSET) [!emacs]: Remove.Stefan Monnier2000-04-021-0/+2
| | | | | | | | | | | | | | | | | | | | (RE_MULTIBYTE_P, RE_STRING_CHAR_AND_LENGTH): New macros. (GET_CHAR_BEFORE_2): Moved from charset.h plus fixed minor bug when we are between str1 and str2. (MAX_MULTIBYTE_LENGTH, CHAR_STRING) [!emacs]: Provide trivial default. (PATFETCH): Use `TRANSLATE'. (PATFETCH_RAW): Fetch multibyte char if applicable. (PATUNFETCH): Remove. (regex_compile): Rely on PATFETCH to do most of the multibyte magic. When writing a char, write it directly into the pattern buffer rather than going needlessly through a temp char-array. (re_match_2_internal): Similarly, rely on RE_STRING_CHAR to do the multibyte magic and remove the useless `#ifdef emacs'. (bcmp_translate): Don't compare as multibyte chars when in a unibyte buffer. * regex.h (struct re_pattern_buffer): Make field `multibyte' conditional on `emacs'. * charset.h (GET_CHAR_BEFORE_2): Moved to regex.c.