History log of /freebsd-current/bin/expr/expr.1
Revision Date Author Comments
# fa9896e0 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

Remove $FreeBSD$: two-line nroff pattern

Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/


# c5ca929f 05-Oct-2016 Sevan Janiyan <sevan@FreeBSD.org>

Document origins of expr & authors
http://minnie.tuhs.org/cgi-bin/utree.pl?file=PWB1/usr/man/man1/expr.1

PR: 173979
Approved by: bcr (mentor)
MFC after: 5 days
Differential Revision: https://reviews.freebsd.org/D8104


# dc814fa4 26-Apr-2015 Baptiste Daroussin <bapt@FreeBSD.org>

Pet manlint


# ef2a65a8 26-Apr-2015 Baptiste Daroussin <bapt@FreeBSD.org>

Use mdoc(7) macros for curly braces


# 35471bf8 13-May-2012 Joel Dahl <joel@FreeBSD.org>

Minor mdoc nits.


# 9d496f5a 25-Feb-2012 Glen Barber <gjb@FreeBSD.org>

Whitespace cleanup:
o Wrap sentences on to new lines
o Cleanup trailing whitespace

Found with: textproc/igor
MFC after: 1 week
X-MFC-With: r232157


# 3102cfe2 25-Feb-2012 Glen Barber <gjb@FreeBSD.org>

Fix various typos in manual pages.

Submitted by: amdmi3
PR: 165431
MFC after: 1 week


# fa717604 08-Jul-2011 Stefan Eßer <se@FreeBSD.org>

Make /bin/expr support 64bit numeric range and range checks by default,
again. This brings back the behaviour of expr in FreeBSD-4, which had been
reverted due to an assumed incompatbility with POSIX.1 for FreeBSD-5.

This issue has been discussed in the freebsd-standards list, and the
consensus was, that POSIX.1 is in fact not violated by this extension,
since it affects only cases of POSIX undefined behaviour (overflow of
signed long).

Other operating systems did upgrade their versions of expr to support
64bit range, after it had been initially brought to FreeBSD. They have
used it for a decade without problems, meanwhile.

The -e option is retained, but it will only select less strict checking
of numeric parameters (leading white-space, leading "+" are allowed and
skipped, an empty string is considered to represent 0 in numeric context.)
The call of check_utility_compat() as a means of establishing backwards
compatibility with FreeBSD-4 is considered obsolete, but preserved in
this commit. It is expected to be removed in a later revision of this
file.
Reviewed by: bde, das, jilles
MFC after: 2 month (those parts that do not violate POLA)


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# f390d8d9 09-Sep-2010 Jilles Tjoelker <jilles@FreeBSD.org>

expr(1): Add sh(1) versions of examples, remove an incorrect example.

The three examples are better done using sh(1) itself these days.

The example
expr -- "$a" : ".*"
is incorrect in the general case, as "$a" may be an operator.

MFC after: 2 weeks


# fe0506d7 09-Mar-2010 Marcel Moolenaar <marcel@FreeBSD.org>

Create the altix project branch. The altix project will add support
for the SGI Altix 350 to FreeBSD/ia64. The hardware used for porting
is a two-module system, consisting of a base compute module and a
CPU expansion module. SGI's NUMAFlex architecture can be an excellent
platform to test CPU affinity and NUMA-aware features in FreeBSD.


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# 9f3cef91 04-Mar-2007 Ruslan Ermilov <ru@FreeBSD.org>

Fix markup.


# 6fca4c7c 16-Jan-2005 Ruslan Ermilov <ru@FreeBSD.org>

Add the new standard EXIT STATUS section where appropriate.
Sort standard sections in the (documented) preferred order.


# 5f05dfac 13-Jan-2005 Ruslan Ermilov <ru@FreeBSD.org>

Removed harmful empty lines that crept in during the copyright
header update.


# 9ddb49cb 10-Jan-2005 Warner Losh <imp@FreeBSD.org>

/*- or .\"- or #- to begin license clauses.


# 5292d2ae 12-Jul-2004 Tim J. Robbins <tjr@FreeBSD.org>

Remove BUGS section that talked about missing multibyte character support.
We have support now that the regular expression routines do.


# 128dc4a2 02-Jul-2004 Tim J. Robbins <tjr@FreeBSD.org>

Document missing multibyte character handling in utilities specified
by POSIX.


# e27480d6 26-Nov-2002 Ruslan Ermilov <ru@FreeBSD.org>

mdoc(7) police:

Revert to using the .Tn POSIX and .Tn ANSI instead of \*[Px] and \*[Ai]
strings; using these strings is unsafe in troff mode, as they include a
change in a font size.

Approved by: re


# 98d13c7e 25-Nov-2002 Ruslan Ermilov <ru@FreeBSD.org>

mdoc(7) police: markup fixes.

Approved by: re


# c9885518 27-Oct-2002 Garrett Wollman <wollman@FreeBSD.org>

Create a small library function, check_utility_compat(3), to determine
whether a named utility should behave in FreeBSD 4.x-compatible mode
or in a standard mode (default standard). The configuration is done
malloc(3)-style, with either an environment variable or a symlink.

Update expr(1) to use this new interface.


# 9dfcbc3b 29-May-2002 Ruslan Ermilov <ru@FreeBSD.org>

mdoc(7) police: markup nits.


# 94a48596 10-May-2002 Garrett Wollman <wollman@FreeBSD.org>

EXPR_COMPAT should imply -e, since there is no way to specify it otherwise,
and -e reflects the historic behavior of FreeBSD's expr.


# 1393277e 10-May-2002 Garrett Wollman <wollman@FreeBSD.org>

The response to my POSIX interpretation request says that `expr'
is required to be oblivious to overflow and to use the data type `long'.
(Division by zero is undefined in ISO C so it's still OK to check for it
here.) Add a new `-e' flag to get the old, more useful behavior.


# 96ab7da3 22-Apr-2002 Garrett Wollman <wollman@FreeBSD.org>

Provide an environment variabloe, EXPR_COMPAT, which disables option
parsing for compatibility with old implementations.


# dc2f94a3 22-Mar-2002 Garrett Wollman <wollman@FreeBSD.org>

Typo (if => of).


# 7316a946 22-Mar-2002 Garrett Wollman <wollman@FreeBSD.org>

Add a word of caution about integer arithmetic range and overflow detection.


# f477880a 22-Mar-2002 Garrett Wollman <wollman@FreeBSD.org>

Fix a few formatting brainos and make the formatting of the EXAMPLES
section somewhat clearer.


# f07e4247 22-Mar-2002 Garrett Wollman <wollman@FreeBSD.org>

Make expr POSIX-compliant, and fix some bugs. Specifically:

- expr must conform to the Utility Syntax Guidelines, so use
getopt() to eat the (non-existent) options.

- Use the Standard type intmax_t for arithmetic.

- If an argument cannot be *completely* converted to an integer, then
it is a string.

Additionally make some style cleanups near the modified lines. This
utility is still not completely style-compliant.


# 7ebcc426 15-Jul-2001 Dima Dorfman <dd@FreeBSD.org>

Remove whitespace at EOL.


# 12e720d7 15-Dec-2000 Ruslan Ermilov <ru@FreeBSD.org>

Prepare for mdoc(7)NG.


# be8b1497 20-Nov-2000 Ruslan Ermilov <ru@FreeBSD.org>

mdoc(7) police: use the new features of the Nm macro.


# 2a456239 27-Aug-1999 Peter Wemm <peter@FreeBSD.org>

$Id$ -> $FreeBSD$


# e5bf7bf4 17-Dec-1998 Joseph Koshy <jkoshy@FreeBSD.org>

Add cross-references to test(1) and expr(1) respectively.

PR: docs/9111
Submitted by: Josh Gilliam <josh@quick.net>


# 15638d89 13-May-1998 Philippe Charnier <charnier@FreeBSD.org>

Correct use of .Nm.


# b97fa2ef 22-Feb-1997 Peter Wemm <peter@FreeBSD.org>

Revert $FreeBSD$ to $Id$


# 1130b656 14-Jan-1997 Jordan K. Hubbard <jkh@FreeBSD.org>

Make the long-awaited change from $Id$ to $FreeBSD$

This will make a number of things easier in the future, as well as (finally!)
avoiding the Id-smashing problem which has plagued developers for so long.

Boy, I'm glad we're not using sup anymore. This update would have been
insane otherwise.


# 7d7ee86e 29-Jan-1996 Mike Pritchard <mpp@FreeBSD.org>

Fix some spelling errors.


# 2caac73e 23-Apr-1994 Jordan K. Hubbard <jkh@FreeBSD.org>

Fix gross spelling and typographical errors pointed out by Keith Bostic.


# d8c21a3e 04-Oct-1993 J.T. Conklin <jtc@FreeBSD.org>

Document the new, less restrictive, behavior of the matching operator.


# c9fe00dc 21-Jul-1993 J.T. Conklin <jtc@FreeBSD.org>

Update to my latest expr (fixes bugs with comparison and matching operators)
Add man page I wrote.