History log of /src/usr.bin/m4/eval.c (Results 1 – 25 of 173)
Revision Date Author Comments
# 507c611a 17-Feb-2026 Dag-Erling Smørgrav <des@FreeBSD.org>

m4: Fix eval output width

According to POSIX, the optional third argument is the minimum number
of digits to print regardless of sign. We interpreted it as the minimum
width of the output including

m4: Fix eval output width

According to POSIX, the optional third argument is the minimum number
of digits to print regardless of sign. We interpreted it as the minimum
width of the output including the sign. Additionally, the variable used
to hold this value was confusingly named “maxdigits”.

PR: 293214
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: imp
Differential Revision: https://reviews.freebsd.org/D55311

show more ...


# 25a8168f 07-Feb-2026 Dag-Erling Smørgrav <des@FreeBSD.org>

m4: Change defn processing order

Currently, defn pushes its arguments on the stack in order, which means
they are then processed in reverse order. POSIX does not specify what
order they are process

m4: Change defn processing order

Currently, defn pushes its arguments on the stack in order, which means
they are then processed in reverse order. POSIX does not specify what
order they are processed in, which arguably suggests that they should be
processed in the order they are listed. Push them in reverse order so
they will be processed in their original order. This matches GNU m4.

PR: 292937
MFC after: 1 week
Sponsored by: Klara, Inc.
Reviewed by: obiwac, imp
Differential Revision: https://reviews.freebsd.org/D55116

show more ...


# ac196a58 23-May-2025 Eric Blake <eblake@redhat.com>

m4: Allow empty base argument in eval()

POSIX specifies "The second argument, if specified, shall set the radix
for the result; if the argument is blank or unspecified, the default
is 10." Previous

m4: Allow empty base argument in eval()

POSIX specifies "The second argument, if specified, shall set the radix
for the result; if the argument is blank or unspecified, the default
is 10." Previously we reported an invalid

PR: 287015
Reviewed by: emaste

show more ...


# 1d386b48 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line .c pattern

Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/


# f993ed2f 09-Sep-2019 Dimitry Andric <dim@FreeBSD.org>

Merge ^/head r351732 through r352104.


# c57596e1 09-Sep-2019 Baptiste Daroussin <bapt@FreeBSD.org>

m4: import from OpenBSD

By deraadt@

mkstemp() returns -1 on failure

Obtained from: OpenBSD


# db531a5d 09-Sep-2019 Baptiste Daroussin <bapt@FreeBSD.org>

m4: import from OpenBSD

patch by espie@

replace sloppy parsing of numeric values with strtonum (incr, decr, divert)

still use integers, so use the natural bounds for these.

POSIX says m4 should e

m4: import from OpenBSD

patch by espie@

replace sloppy parsing of numeric values with strtonum (incr, decr, divert)

still use integers, so use the natural bounds for these.

POSIX says m4 should error when these use non numeric values, and now they
do.

okay millert@

Obtained from: OpenBSD

show more ...


# e0f4e041 09-Sep-2019 Baptiste Daroussin <bapt@FreeBSD.org>

m4: import patch from OpenBSD

by espie@
ifelse is special, fix argv parsing to avoid segfault

problem noticed by Matthew Green (netbsd), slightly different fix
so that argc counting makes more sens

m4: import patch from OpenBSD

by espie@
ifelse is special, fix argv parsing to avoid segfault

problem noticed by Matthew Green (netbsd), slightly different fix
so that argc counting makes more sense.

we might want to warn on wrong number of parameters later, but this is
somewhat inconsistent depending on the builtin right now.

okay millert@

Obtained from: OpenBSD

show more ...


# c560b67c 09-Sep-2019 Baptiste Daroussin <bapt@FreeBSD.org>

Import from OpenBSD: -E flag

Add -E flag (make warnings fatal), following the behavior of GNU m4 1.4.9+

Help and direction millert@ espie@ anton@ deraadt@

ok espie@

Obtained from: OpenBSD


# ac196a58 23-May-2025 Eric Blake <eblake@redhat.com>

m4: Allow empty base argument in eval()

POSIX specifies "The second argument, if specified, shall set the radix
for the result; if the argument is blank or unspecified, the default
is 10." Previous

m4: Allow empty base argument in eval()

POSIX specifies "The second argument, if specified, shall set the radix
for the result; if the argument is blank or unspecified, the default
is 10." Previously we reported an invalid

PR: 287015
Reviewed by: emaste

show more ...


# 1d386b48 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: one-line .c pattern

Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/


# f993ed2f 09-Sep-2019 Dimitry Andric <dim@FreeBSD.org>

Merge ^/head r351732 through r352104.


# c57596e1 09-Sep-2019 Baptiste Daroussin <bapt@FreeBSD.org>

m4: import from OpenBSD

By deraadt@

mkstemp() returns -1 on failure

Obtained from: OpenBSD


# db531a5d 09-Sep-2019 Baptiste Daroussin <bapt@FreeBSD.org>

m4: import from OpenBSD

patch by espie@

replace sloppy parsing of numeric values with strtonum (incr, decr, divert)

still use integers, so use the natural bounds for these.

POSIX says m4 should e

m4: import from OpenBSD

patch by espie@

replace sloppy parsing of numeric values with strtonum (incr, decr, divert)

still use integers, so use the natural bounds for these.

POSIX says m4 should error when these use non numeric values, and now they
do.

okay millert@

Obtained from: OpenBSD

show more ...


# e0f4e041 09-Sep-2019 Baptiste Daroussin <bapt@FreeBSD.org>

m4: import patch from OpenBSD

by espie@
ifelse is special, fix argv parsing to avoid segfault

problem noticed by Matthew Green (netbsd), slightly different fix
so that argc counting makes more sens

m4: import patch from OpenBSD

by espie@
ifelse is special, fix argv parsing to avoid segfault

problem noticed by Matthew Green (netbsd), slightly different fix
so that argc counting makes more sense.

we might want to warn on wrong number of parameters later, but this is
somewhat inconsistent depending on the builtin right now.

okay millert@

Obtained from: OpenBSD

show more ...


# c560b67c 09-Sep-2019 Baptiste Daroussin <bapt@FreeBSD.org>

Import from OpenBSD: -E flag

Add -E flag (make warnings fatal), following the behavior of GNU m4 1.4.9+

Help and direction millert@ espie@ anton@ deraadt@

ok espie@

Obtained from: OpenBSD


# 82725ba9 23-Nov-2017 Hans Petter Selasky <hselasky@FreeBSD.org>

Merge ^/head r325999 through r326131.


# 8a16b7a1 20-Nov-2017 Pedro F. Giffuni <pfg@FreeBSD.org>

General further adoption of SPDX licensing ID tags.

Mainly focus on files that use BSD 3-Clause license.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier f

General further adoption of SPDX licensing ID tags.

Mainly focus on files that use BSD 3-Clause license.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.

Special thanks to Wind River for providing access to "The Duke of
Highlander" tool: an older (2014) run over FreeBSD tree was useful as a
starting point.

show more ...


# af7ca7c8 01-May-2016 Pedro F. Giffuni <pfg@FreeBSD.org>

usr.bin: minor spelling fixes on comments.

No functional change.


# b626f5a7 04-Jan-2016 Glen Barber <gjb@FreeBSD.org>

MFH r289384-r293170

Sponsored by: The FreeBSD Foundation


# 8d4f972b 26-Nov-2015 Navdeep Parhar <np@FreeBSD.org>

Catch up with head.


# 46ef9581 21-Nov-2015 Baptiste Daroussin <bapt@FreeBSD.org>

Synchronize m4(1) with OpenBSD


# 246e7a2b 02-Sep-2014 Neel Natu <neel@FreeBSD.org>

IFC @r269962

Submitted by: Anish Gupta (akgupt3@gmail.com)


# ee7b0571 19-Aug-2014 Simon J. Gerraty <sjg@FreeBSD.org>

Merge head from 7/28


# 1b833d53 13-Aug-2014 Alexander V. Chernikov <melifaro@FreeBSD.org>

Sync to HEAD@r269943.


1234567