Fixed a \-escape bug in calc(1) man page.
Added cal/comma.cal:
Convert numbers into strings with 3-digit group and integer-fraction
separators.
If the value is an integer, the integer-fraction separator is not used.
str_comma(x, [group, [decimal]])
Convert x into a string.
If group is given and is a string, group will be used as
the 3-digit group separator, otherwise the default 3-digit
group separator will be used.
If decimal is given and is a string, group will be used as
the integer-fraction separator, otherwise the default
integer-fraction separator will be used.
The decimal and group arguments are optional.
set_default_group_separator(group)
Change the default 3-digit group separator if group is a string,
otherwise the default 3-digit group separator will not be
changed. Return the old 3-digit group separator.
set_default_decimal_separator(decimal)
Change the default 3-digit group separator if decimal is a
string, otherwise the default integer-fraction separator
will not be changed. Return the old integer-fraction separator.
print_comma(x, [group, [decimal]])
Print the value produced by str_comma(x, [group, [decimal]])
followed by a newline.
If the str_comma() does not return a string, nothing is printed.
The decimal and group arguments are optional.
The value produced by str_comma() is returned.
fprint_comma(fd, x, [group, [decimal]])
Print the value produced by str_comma(x, [group, [decimal]]),
without a trailing newline, on file fd.
If the str_comma() does not return a string, nothing is printed.
If fd is not an open file, nothing is printed.
The decimal and group arguments are optional.
The value produced by str_comma() is returned.
The following are the changes from calc version 2.14.1.0 to date:
Fixed alignment of show item section of help command.
Bug fix: While 0^0 == 1, now for y > 0, 0^y == 0.
Adjusted cal/test8900.cal to reflect this bug fix.
Added tests to cal/regress.cal to help verify bug fix is fixed.
While 0^0 == 1, now for y > 0, 0^y == 0.
Adjusted cal/test8900.cal to reflect the this bug fix.
Added tests to cal/regress.cal to help verify bug fix is fixed.
Changed /*NOTREACHED*/ to not_reached(); and use "attribute.h".
Added .PHONY rule, just after all rule, to Makefiles.
Fixed an improper indentation issue.
Expanded the globalsymbol string table size: from 1024 to 65536.
Expanded the how often to reallocate string table is performed:
from 100 to 1024.
Expanded the number env_pool elements to allocate at a time:
from 10 to 256.
Improve comments on Makefile.local and add a few more examples
of how it might be used.
Changed Makefile to set shell before setting the SHELL Makefile
variable.
Added text to HOWTO.INSTALL to help people with systems that
lack the readline package.
Trimmed long line in the CONTRIBUTING.md file.
The following are the changes in this release:
Fixed typo in Makefile.local comment.
Established a tagging procedure for a production release.
Production git tags will be of the form:
prod-2.x.y.z
We apologize for the calc v2.14.0.12 source tarball that was missing
critical files. While the executable was well tested, our release
process was deficient.
We are improved our release process and added tests during the release
procedure to help verify that we are not regressing in to the
"v2.14.0.12 source tarball" issue, among other things.
Depending on how things do, you might is several releases come out over
a short period of time. The core of calc isn't changing, so the calc
executable will be the same as we focus on the Makefiles, our release
procedure, and related documentation / help files.
Removed constructed help file that incorrectly added as a src file.
=-=
The following are the changes in this release:
Made major changes to our release process in order to avoid
missing critical files that happened in calc v2.4.0.12.
Minor tweak to seed() builtin. Updated help/srand and help/srandom.
Moved Makefile.ship into Makefile.
Removed custom/Makefile.head and custom/Makefile.tail.
The custom/Makefile is now part of source and includes Makefile.
In particular, custom/Makefile makes use of the 'middle' of
the new top level Makefile where calc's top level Makefile
variables are defined.
Makefile.simple and custom/Makefile.simple are now part of the source
and are constructed from Makefile and custom/Makefile respectively.
The Makefile.simple and custom/Makefile.simple avoid using GNU
conditionals. They may be used with older/classic make commands.
Makefile.local will include comments about how to better use
it. Between releases, Makefile.local at the top of the master branch
will contain how we typically build calc and test calc (FYI: we
normally enable things such as -Werror -Wextra -pedantic). When we
push out a release, Makefile.local will be stripped of non-comment
lines. Thus, releases of calc, and, released "calc*.src.rpm"
files and the source tarballs, will have a Makefile.local with
only comments.
The "README.*" files and "HOWTO.INSTALL" file have been updated.
By default, compiler warnings have been turned up. The Makefile
variable ${CCWARN} now defaults to:
CCWARN= -Wall -Wextra -pedantic
The previous level of compiler warnings can be easily restored by
adding to Makefile.local:
CCWARN:= -Wall
The readline, history and ncurses libraries are now default.
The Makefile variables ${USE_READLINE}, ${READLINE_LIB}, and
${READLINE_EXTRAS} now default to:
USE_READLINE= -DUSE_READLINE
READLINE_LIB= -lreadline
READLINE_EXTRAS= -lhistory -lncurses
The previous mode where readline, history and ncurses libraries
were not compiled in by default can be easily restored by
adding to Makefile.local:
USE_READLINE:=
READLINE_LIB:=
READLINE_EXTRAS:=
We have renamed "stable" as "production".
We have renamed "unstable" as "tested".
On the web site:
http://www.isthe.com/chongo/src/calc/
these files has been renamed:
2.x.y.z_IS_LATEST_STABLE ==> 2.x.y.z_IS_LATEST_PRODUCTION
2.x.y.z_IS_LATEST_UNSTABLE ==> 2.x.y.z_IS_LATEST_TESTED
The terms 'stable' and 'unstable' were both misleading and
inaccurate. For details see the new documention file:
README.RELEASE
See also the help command:
; help release
Fixed bug impacting how have_ustat.h was formed.
Updated help/archive, BUGS, HOWTO.INSTALL to reflect GitHub use.
We apologize for the calc v2.14.0.12 source tarball that was missing
critical files. While the executable was well tested, our release
process was deficient.
We are improved our release process and added tests during the release
procedure to help verify that we are not regressing in to the "v2.14.0.12
source tarball" issue, among other things.
Depending on how things do, you might is several releases come out over
a short period of time. The core of calc isn't changing, so the calc
executable will be the same as we focus on the Makefiles, our release
procedure, and related documentation / help files.
Removed constructed help file that incorrectly added as a src file.
=-=
The following are the changes in this release:
Minor tweak to seed() builtin. Updated help/srand and help/srandom.
Moved Makefile.ship into Makefile.
Removed custom/Makefile.head and custom/Makefile.tail.
The custom/Makefile is now part of source and includes Makefile.
In particular, custom/Makefile makes use of the 'middle' of
the new top level Makefile where calc's top level Makefile
variables are defined.
Makefile.simple and custom/Makefile.simple are now part of the source
and are constructed from Makefile and custom/Makefile respectively.
The Makefile.simple and custom/Makefile.simple avoid using GNU
conditionals. They may be used with older/classic make commands.
Makefile.local will include comments about how to better use
it. Between releases, Makefile.local at the top of the master branch
will contain how we typically build calc and test calc (FYI: we
normally enable things such as -Werror -Wextra -pedantic). When we
push out a release, Makefile.local will be stripped of non-comment
lines. Thus, releases of calc, and, released "calc*.src.rpm"
files and the source tarballs, will have a Makefile.local with
only comments.
The "README.*" files and "HOWTO.INSTALL" file have been updated.
By default, compiler warnings have been turned up. The Makefile
variable ${CCWARN} now defaults to:
CCWARN= -Wall -Wextra -pedantic
The previous level of compiler warnings can be easily restored by
adding to Makefile.local:
CCWARN:= -Wall
The readline, history and ncurses libraries are now default.
The Makefile variables ${USE_READLINE}, ${READLINE_LIB}, and
${READLINE_EXTRAS} now default to:
USE_READLINE= -DUSE_READLINE
READLINE_LIB= -lreadline
READLINE_EXTRAS= -lhistory -lncurses
The previous mode where readline, history and ncurses libraries
were not compiled in by default can be easily restored by
adding to Makefile.local:
USE_READLINE:=
READLINE_LIB:=
READLINE_EXTRAS:=
We have renamed "stable" as "production".
We have renamed "unstable" as "tested".
On the web site:
http://www.isthe.com/chongo/src/calc/
these files has been renamed:
2.x.y.z_IS_LATEST_STABLE ==> 2.x.y.z_IS_LATEST_PRODUCTION
2.x.y.z_IS_LATEST_UNSTABLE ==> 2.x.y.z_IS_LATEST_TESTED
The terms 'stable' and 'unstable' were both misleading and
inaccurate. For details see the new documention file:
README.RELEASE
See also the help command:
; help release
Fixed bug impacting how have_ustat.h was formed.
Updated help/archive to reflect GitHub use.
We apologize for the calc v2.14.0.12 source tarball that was missing
critical files. While the executable was well tested, our release
process was deficient.
We are improved our release process and added tests during the release
procedure to help verify that we are not regressing in to the "v2.14.0.12
source tarball" issue, among other things.
Depending on how things do, you might is several releases come out over
a short period of time. The core of calc isn't changing, so the calc
executable will be the same as we focus on the Makefiles, our release
procedure, and related documentation / help files.
=-=
The following are the changes in this release:
Minor tweak to seed() builtin. Updated help/srand and help/srandom.
Moved Makefile.ship into Makefile.
Removed custom/Makefile.head and custom/Makefile.tail.
The custom/Makefile is now part of source and includes Makefile.
In particular, custom/Makefile makes use of the 'middle' of
the new top level Makefile where calc's top level Makefile
variables are defined.
Makefile.simple and custom/Makefile.simple are now part of the source
and are constructed from Makefile and custom/Makefile respectively.
The Makefile.simple and custom/Makefile.simple avoid using GNU
conditionals. They may be used with older/classic make commands.
Makefile.local will include comments about how to better use
it. Between releases, Makefile.local at the top of the master branch
will contain how we typically build calc and test calc (FYI: we
normally enable things such as -Werror -Wextra -pedantic). When we
push out a release, Makefile.local will be stripped of non-comment
lines. Thus, releases of calc, and, released "calc*.src.rpm"
files and the source tarballs, will have a Makefile.local with
only comments.
The "README.*" files and "HOWTO.INSTALL" file have been updated.
By default, compiler warnings have been turned up. The Makefile
variable ${CCWARN} now defaults to:
CCWARN= -Wall -Wextra -pedantic
The previous level of compiler warnings can be easily restored by
adding to Makefile.local:
CCWARN:= -Wall
The readline, history and ncurses libraries are now default.
The Makefile variables ${USE_READLINE}, ${READLINE_LIB}, and
${READLINE_EXTRAS} now default to:
USE_READLINE= -DUSE_READLINE
READLINE_LIB= -lreadline
READLINE_EXTRAS= -lhistory -lncurses
The previous mode where readline, history and ncurses libraries
were not compiled in by default can be easily restored by
adding to Makefile.local:
USE_READLINE:=
READLINE_LIB:=
READLINE_EXTRAS:=
We have renamed "stable" as "production".
We have renamed "unstable" as "tested".
On the web site:
http://www.isthe.com/chongo/src/calc/
these files has been renamed:
2.x.y.z_IS_LATEST_STABLE ==> 2.x.y.z_IS_LATEST_PRODUCTION
2.x.y.z_IS_LATEST_UNSTABLE ==> 2.x.y.z_IS_LATEST_TESTED
The terms 'stable' and 'unstable' were both misleading and
inaccurate. For details see the new documention file:
README.RELEASE
See also the help command:
; help release
Fixed bug impacting how have_ustat.h was formed.
Updated help/archive to reflect GitHub use.
We apologize for the calc v2.14.0.12 source tarball that was missing
critical files. While the executable was well tested, our release
process was deficient.
We are improved our release process and added tests during the release
procedure to help verify that we are not regressing in to the "v2.14.0.12
source tarball" issue, among other things.
Depending on how things do, you might is several releases come out over
a short period of time. The core of calc isn't changing, so the calc
executable will be the same as we focus on the Makefiles, our release
procedure, and related documentation / help files.
We made several changes to the Makefiles. We also added a new
README.RELEASE document (see "help release") that is a work in
progress. Along the way we discovered a few things that needed to be
updated in documentation.
See the CHANGES file for details.
The following are the changes in this release:
Fixed a number of typos.
Drop support for SunOS, IRIX and MINGW32_NT-5.0 targets.
Drop support for CLOCK_SGI_CYCLE. Drop testing for __MSDOS__.
Minor improvement of various help files. Made format of help
files more consistent.
Corrected a few comments in zrandom.c, including a case where
the comment referred to 1007 when it should have used 2^32.
Improved seed() generation. Improved some comments in seed.c.
Added have_environ.c to build have_environ.h in order to
determine if:
extern char **environ; /* user environment */
is an valid external symbol.
Fixed documentation that referred to the old additive 55
generator. We have been using the subtractive 100 in place
of the additive 55 generator for a while now.
Fixed depend rule for custom/Makefile.
Fixed how Makefile variable SHELL is set on macOS vs. Linux.
Using /bin/sh on macOS due to how zsh treats globs by default.
Added charbit.h to define CALC_CHARBIT which is either CHAR_BIT
from <limits.h> or 8 or a value set by the Makefile variable
CALC_CHARBIT. Added have_limits.h to determine if <limits.h>
is a system include file.
Compiling now tests for _WIN64 as well when testing for _WIN32.
Now assuming that <stdio.h> is available under _WIN32 and _WIN64.
Added some preliminary notes about attempts to compile calc
under Windows 11.
BTW: While we are unable to use Windows 11, we welcome
Windows 11 developers to try compiling calc natively
(instead of via a Linux virtual machine). If you are
able to compile Windows 11 natively, we would welcome
GitHub pull requests showing any needed modifications:
https://github.com/lcn2/calc/pulls
Please also add notes to the 'Compiling calc under Windows 11'
section in README.WINDOWS file.
We added Makefile.simple as part of the master branch source
to help those who may be using a make tool that does not support
GNU Make-like features such as "ifeq" and ":=".
Fixed incorrect ustat_dev member ref in seed() builtin that
was part of the unreleased calc v2.12.0.11.
The following are the changes in this release:
Fixed a number of typos.
Drop support for SunOS, IRIX and MINGW32_NT-5.0 targets.
Drop support for CLOCK_SGI_CYCLE. Drop testing for __MSDOS__.
Minor improvement of various help files. Made format of help
files more consistent.
Corrected a few comments in zrandom.c, including a case where
the comment referred to 1007 when it should have used 2^32.
Improved seed() generation. Improved some comments in seed.c.
Added have_environ.c to build have_environ.h in order to
determine if:
extern char **environ; /* user environment */
is an valid external symbol.
Fixed documentation that referred to the old additive 55
generator. We have been using the subtractive 100 in place
of the additive 55 generator for a while now.
Fixed depend rule for custom/Makefile.
Fixed how Makefile variable SHELL is set on macOS vs. Linux.
Using /bin/sh on macOS due to how zsh treats globs by default.
Added charbit.h to define CALC_CHARBIT which is either CHAR_BIT
from <limits.h> or 8 or a value set by the Makefile variable
CALC_CHARBIT. Added have_limits.h to determine if <limits.h>
is a system include file.
Compiling now tests for _WIN64 as well when testing for _WIN32.
Now assuming that <stdio.h> is available under _WIN32 and _WIN64.
Added some preliminary notes about attempts to compile calc
under Windows 11.
BTW: While we are unable to use Windows 11, we welcome
Windows 11 developers to try compiling calc natively
(instead of via a Linux virtual machine). If you are
able to compile Windows 11 natively, we would welcome
GitHub pull requests showing any needed modifications:
https://github.com/lcn2/calc/pulls
Please also add notes to the 'Compiling calc under Windows 11'
section in README.WINDOWS file.
We added Makefile.simple as part of the master branch source
to help those who may be using a make tool that does not support
GNU Make-like features such as "ifeq" and ":=".
Fixed incorrect ustat_dev member ref in seed() builtin that
was part of the unreleased calc v2.12.0.11.