mbox series

[v5,00/13] Add multi-byte supportAdd multi-byte support

Message ID cover.1717291579.git.herbert@gondor.apana.org.au (mailing list archive)
Headers show
Series Add multi-byte supportAdd multi-byte support | expand

Message

Herbert Xu June 2, 2024, 1:28 a.m. UTC
v5 rebases on top of the expmeta resource leakage patch.

This patch series adds multi-byte support to dash.  For now only
fnmatch is supported as the native pmatch function has not been
modified to support multi-byte characters.

Herbert Xu (13):
  shell: Call setlocale
  shell: Use strcoll instead of strcmp where applicable
  expand: Count multi-byte characters for VSLENGTH
  expand: Process multi-byte characters in subevalvar
  expand: Process multi-byte characters in expmeta
  expand: Support multi-byte characters during field splitting
  expand: Add multi-byte support to pmatch
  input: Allow MB_LEN_MAX calls to pungetc
  input: Add pgetc_eoa
  parser: Add support for multi-byte characters
  input: Always push in setinputfile
  builtin: Use pgetc in read(1)
  builtin: Process multi-byte characters in read(1)

 src/bltin/test.c |    8 +-
 src/eval.c       |    3 +-
 src/expand.c     | 1019 +++++++++++++++++++++++++++++++++-------------
 src/expand.h     |    2 +
 src/input.c      |  119 ++++--
 src/input.h      |   15 +-
 src/main.c       |    4 +
 src/memalloc.h   |   10 +-
 src/miscbltin.c  |   58 +--
 src/mktokens     |    1 +
 src/mystring.c   |    2 +-
 src/parser.c     |  136 +++++--
 src/parser.h     |    2 +
 src/var.c        |   12 +-
 14 files changed, 978 insertions(+), 413 deletions(-)