| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
Problem: Alloc() returning "char_u *" causes a lot of type casts.
Solution: Have it return "void *". (Mike Williams) Define ALLOC_ONE() to
check the simple allocations.
|
|
|
|
|
| |
Problem: Unnecessary type casts.
Solution: Remove type casts from alloc() and lalloc() calls. (Mike Williams)
|
|
|
|
|
| |
Problem: Unessesary type casts for lalloc().
Solution: Remove type casts. Change lalloc(size, TRUE) to alloc(size).
|
|
|
|
|
| |
Problem: Compiler warning for uninitialized variable.
Solution: Initialize it. (Christian Brabandt)
|
|
|
|
|
|
| |
Problem: Too many curly braces.
Solution: Remove curly braces where they are not needed. (Hirohito Higashi,
closes #3982)
|
|
|
|
|
|
|
| |
Problem: Pattern with syntax error gives threee error messages. (Kuang-che
Wu)
Solution: Remove outdated internal error. Don't fall back to other engine
after an error.
|
|
|
|
|
| |
Problem: Crash when using search pattern \%Ufffffc23.
Solution: Limit character to INT_MAX. (closes #4009)
|
|
|
|
|
|
| |
Problem: Compiling weird regexp pattern is very slow.
Solution: When reallocating post list increase size by 50%. (Kuang-che Wu,
closes #4012) Make assert_inrange() accept float values.
|
|
|
|
|
|
| |
Problem: Internal error when using pattern with NL in the range.
Solution: Use an actual newline for the range. (closes #3989) Also fix
error message. (Dominique Pelle)
|
|
|
|
|
| |
Problem: Compiler warnings.
Solution: Add type casts. (Mike Williams)
|
|
|
|
|
| |
Problem: CI crashes when running out of memory.
Solution: Apply 'maxmempattern' also to new regexp engine.
|
|
|
|
|
| |
Problem: Crash with tricky search pattern. (Kuang-che Wu)
Solution: Check for runnning out of memory. (closes #3950)
|
|
|
|
|
| |
Problem: Can't handle large value for %{nr}v in regexp. (Kuang-che Wu)
Solution: Give an error if the value is too large. (closes #3948)
|
|
|
|
|
| |
Problem: CI tests on AppVeyor are failing.
Solution: Reduce the recursiveness limit for regexp.
|
|
|
|
|
| |
Problem: Complicated regexp causes a crash. (Kuang-che Wu)
Solution: Limit the recursiveness of addstate(). (closes #3941)
|
|
|
|
|
|
| |
Problem: No verbose version of character classes.
Solution: Add [:ident:], [:keyword:] and [:fname:]. (Ozaki Kiichi,
closes #1373)
|
|
|
|
|
| |
Problem: Too many #ifdefs.
Solution: Graduate FEAT_MBYTE, part 3.
|
|
|
|
|
|
| |
Problem: printf format not checked for semsg().
Solution: Add GNUC attribute and fix reported problems. (Dominique Pelle,
closes #3805)
|
|
|
|
|
|
|
|
| |
Problem: Giving error messages is not flexible.
Solution: Add semsg(). Change argument from "char_u *" to "char *", also
for msg() and get rid of most MSG macros. (Ozaki Kiichi, closes
#3302) Also make emsg() accept a "char *" argument. Get rid of
an enormous number of type casts.
|
|
|
|
|
| |
Problem: No check for out-of-memory when converting regexp.
Solution: Bail out when lalloc() returns NULL. (John Marriott)
|
|
|
|
|
| |
Problem: Executing regexp recursively fails with a crash.
Solution: Move global variables into "rex".
|
|
|
|
|
|
| |
Problem: Invalid memory use with complicated pattern. (Andy Massimino)
Solution: Reallocate the list of listids when needed. (closes #3175)
Remove unnecessary function prototypes.
|
|
|
|
|
| |
Problem: Can't build without the +eval feature.
Solution: Add #ifdef.
|
|
|
|
|
| |
Problem: Exclamation mark in error message not needed.
Solution: Remove the exclamation mark.
|
|
|
|
|
|
| |
Problem: Segfault when pattern with \z() is very slow.
Solution: Check for NULL regprog. Add "nfa_fail" to test_override() to be
able to test this. Fix that 'searchhl' resets called_emsg.
|
|
|
|
|
| |
Problem: Superfluous space before exclamation mark.
Solution: Remove the space. Don't translate debug message.
|
|
|
|
|
| |
Problem: "..." used inconsistently in a message.
Solution: Define the message with " ..." once. (hint by Ken Takata)
|
|
|
|
|
| |
Problem: "..." used inconsistently in messages.
Solution: Drop the space before " ...".
|
|
|
|
|
|
| |
Problem: Clearing a pointer takes two lines.
Solution: Add VIM_CLEAR() and replace vim_clear(). (Hirohito Higashi,
closes #2629)
|
|
|
|
|
| |
Problem: Unnecessary condition for "len" being zero.
Solution: Remove the condition. (Dominique Pelle)
|
|
|
|
|
| |
Problem: Integer overflow when using regexp pattern. (geeknik)
Solution: Use a long instead of int. (Christian Brabandt, closes #2251)
|
|
|
|
|
| |
Problem: Pattern with \& following nothing gives an error.
Solution: Emit an empty node when needed.
|
|
|
|
|
| |
Problem: Undefined left shift in gethexchrs(). (geeknik)
Solution: Use unsigned long. (idea by Christian Brabandt, closes #2255)
|
|
|
|
|
| |
Problem: Newer gcc warns for implicit fallthrough.
Solution: Consistently use a FALLTHROUGH comment. (Christian Brabandt)
|
|
|
|
|
| |
Problem: Coverity: may dereference NULL pointer.
Solution: Bail out if calloc_state() returns NULL.
|
|
|
|
|
|
| |
Problem: The new regexp engine does not give an error for using a back
reference where it is not allowed. (Dominique Pelle)
Solution: Check the back reference like the old engine. (closes #1774)
|
|
|
|
|
|
|
|
| |
Problem: When 'hlsearch' is set and matching with the last search pattern
is very slow, Vim becomes unusable. Cannot quit search by
pressing CTRL-C.
Solution: When the search times out set a flag and don't try again. Check
for timeout and CTRL-C in NFA loop that adds states.
|
|
|
|
|
| |
Problem: The message "Invalid range" is used for multiple errors.
Solution: Add two more specific error messages. (Itchyny, Ken Hamada)
|
|
|
|
|
| |
Problem: NFA regex engine handles [0-z] incorrectly.
Solution: Return at the right point. (James McCoy, closes #1703)
|
|
|
|
|
|
|
| |
Problem: Using a function pointer instead of the actual function, which we
know.
Solution: Change mb_ functions to utf_ functions when already checked for
Unicode. (Dominique Pelle, closes #1582)
|
|
|
|
|
|
|
|
|
| |
Problem: Character classes are not well tested. They can differ between
platforms.
Solution: Add tests. In the documentation make clear which classes depend
on what library function. Only use :cntrl: and :graph: for ASCII.
(Kazunobu Kuriyama, Dominique Pelle, closes #1560)
Update the documentation.
|
|
|
|
|
| |
Problem: Some macros are in lower case.
Solution: Make a few more macros upper case.
|
|
|
|
|
|
| |
Problem: Some macros are in lower case.
Solution: Make a few more macros upper case. Avoid lower case macros use an
argument twice.
|
|
|
|
|
| |
Problem: Ubsan warns for integer overflow.
Solution: Swap two conditions. (Dominique Pelle)
|
|
|
|
|
| |
Problem: EMSG() is sometimes used for internal errors.
Solution: Change them to IEMSG(). (Dominique Pelle) And a few more.
|
|
|
|
|
| |
Problem: The regexp engines are not reentrant.
Solution: Add regexec_T and save/restore the state when needed.
|
|
|
|
|
|
| |
Problem: Regexp fails to match when using "\>\)\?". (Ramel)
Solution: When a state is already in the list, but addstate_here() is used
and the existing state comes later, add the new state anyway.
|
|
|
|
|
|
| |
Problem: The example that explains nested backreferences does not work
properly with the new regexp engine. (Harm te Hennepe)
Solution: Also save the end position when adding a state. (closes #990)
|
|
|
|
|
| |
Problem: Modelines in source code are inconsistant.
Solution: Use the same line in most files. Add 'noet'. (Naruhiko Nishino)
|
|
|
|
|
|
| |
Problem: Falling back from NFA to old regexp engine does not work properly.
(fritzophrenic)
Solution: Do not restore nfa_match. (Christian Brabandt, closes #867)
|