2020-07-07 07:02:33 +00:00
|
|
|
|
$ $
|
|
|
|
|
$ SPDX-License-Identifier: BSD-2-Clause
|
|
|
|
|
$ $
|
2021-01-31 19:56:48 +00:00
|
|
|
|
$ Copyright (c) 2018-2021 Gavin D. Howard and contributors.
|
2020-07-07 07:02:33 +00:00
|
|
|
|
$ $
|
|
|
|
|
$ Redistribution and use in source and binary forms, with or without
|
|
|
|
|
$ modification, are permitted provided that the following conditions are met:
|
|
|
|
|
$ $
|
|
|
|
|
$ * Redistributions of source code must retain the above copyright notice, this
|
|
|
|
|
$ list of conditions and the following disclaimer.
|
|
|
|
|
$ $
|
|
|
|
|
$ * Redistributions in binary form must reproduce the above copyright notice,
|
|
|
|
|
$ this list of conditions and the following disclaimer in the documentation
|
|
|
|
|
$ and/or other materials provided with the distribution.
|
|
|
|
|
$ $
|
|
|
|
|
$ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
|
|
|
$ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
|
|
|
$ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
|
|
|
$ ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
|
|
|
|
|
$ LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
|
|
|
|
$ CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
|
|
|
|
$ SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
|
|
|
|
$ INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
|
|
|
|
$ CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
|
|
|
|
$ ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
|
|
|
|
$ POSSIBILITY OF SUCH DAMAGE.
|
|
|
|
|
$ $
|
|
|
|
|
|
Import new 2-clause BSD licenced implementation of the bc and dc commands
These implementations of the bc and dc programs offer a number of advantages
compared to the current implementations in the FreeBSD base system:
- They do not depend on external large number functions (i.e. no dependency
on OpenSSL or any other large number library)
- They implements all features found in GNU bc/dc (with the exception of
the forking of sub-processes, which the author of this version considers
as a security issue).
- They are significantly faster than the current code in base (more than
2 orders of magnitude in some of my tests, e.g. for 12345^100000).
- They should be fully compatible with all features and the behavior of the
current implementations in FreeBSD (not formally verified).
- They support POSIX message catalogs and come with localized messages in
Chinese, Dutch, English, French, German, Japanese, Polish, Portugueze,
and Russian.
- They offer very detailed man-pages that provide far more information than
the current ones.
Approved by: imp
Obtained from: https://git.yzena.com/gavin/bc
Differential Revision: https://reviews.freebsd.org/D19982
2020-06-27 15:03:19 +00:00
|
|
|
|
$quote "
|
|
|
|
|
|
|
|
|
|
$ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ᮮ<>饭<EFBFBD><E9A5AD>.
|
|
|
|
|
$set 1
|
|
|
|
|
|
|
|
|
|
1 "<22>㭪<EFBFBD><E3ADAA><EFBFBD>:"
|
|
|
|
|
|
|
|
|
|
$ <20><><EFBFBD><EFBFBD> <20>訡<EFBFBD><E8A8A1>.
|
|
|
|
|
$set 2
|
|
|
|
|
|
|
|
|
|
1 "<22><>⥬<EFBFBD><E2A5AC><EFBFBD><EFBFBD><EFBFBD>᪠<EFBFBD> <20>訡<EFBFBD><E8A8A1>:"
|
|
|
|
|
2 "<22>訡<EFBFBD><E8A8A1> <20><><EFBFBD> ࠧ<><E0A0A7><EFBFBD><EFBFBD>:"
|
|
|
|
|
3 "<22>訡<EFBFBD><E8A8A1> <20>믮<EFBFBD><EBAFAE><EFBFBD><EFBFBD><EFBFBD><EFBFBD>:"
|
|
|
|
|
4 "<22><>⠫쭠<E2A0AB> <20>訡<EFBFBD><E8A8A1>:"
|
|
|
|
|
5 "<22>।<EFBFBD><E0A5A4>०<EFBFBD><E0A5A6><EFBFBD><EFBFBD><EFBFBD>:"
|
|
|
|
|
|
|
|
|
|
$ <20><>⥬<EFBFBD><E2A5AC><EFBFBD><EFBFBD><EFBFBD>᪨<EFBFBD> <20>訡<EFBFBD><E8A8A1>.
|
|
|
|
|
$set 3
|
|
|
|
|
|
|
|
|
|
1 "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⥫쭮<E2A5AB> <20><>"
|
|
|
|
|
2 "<22><><EFBFBD><EFBFBD>⥣<EFBFBD><E2A5A3><EFBFBD><E0AEA2><EFBFBD><EFBFBD><EFBFBD> <20><>"
|
|
|
|
|
3 "<22><>९<EFBFBD><E0A5AF><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: <20><><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD>頥<EFBFBD><E9A0A5><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
4 "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> 0"
|
|
|
|
|
|
|
|
|
|
$ <20>訡<EFBFBD><E8A8A1> <20><><EFBFBD> ࠧ<><E0A0A7><EFBFBD><EFBFBD>.
|
|
|
|
|
$set 4
|
|
|
|
|
|
|
|
|
|
1 "<22><><EFBFBD><EFBFBD><EFBFBD> 䠩<><E4A0A9>"
|
|
|
|
|
2 "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⨬<EFBFBD><E2A8AC> ᨬ<><E1A8AC><EFBFBD> '%c'"
|
|
|
|
|
3 "<22><><EFBFBD><EFBFBD><EFBFBD> <20><>ப<EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
4 "<22><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
5 "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢨⥫<E2A2A8><E2A5AB><EFBFBD><EFBFBD> <20><>⮭"
|
|
|
|
|
6 "<22><><EFBFBD>ࠢ<EFBFBD><E0A0A2>쭮<EFBFBD> <20><>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>"
|
|
|
|
|
7 "<22><><EFBFBD>⮥ <20><>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>"
|
|
|
|
|
8 "<22><><EFBFBD><EFA2AB><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢨⥫쭮<E2A5AB><ECADAE><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
9 "<22><>।<EFBFBD><E0A5A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢨⥫쭮<E2A5AB> <20>㭪樨"
|
|
|
|
|
10 "<22><><EFBFBD><EFBFBD>୮<EFBFBD> <20><><EFBFBD><EFBFBD><E1A2AE><EFBFBD><EFBFBD>: <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> scale, ibase, obase, last, <20><> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⮬ <20><><EFBFBD>ᨢ<EFBFBD>"
|
|
|
|
|
11 "<22><>⮬<EFBFBD><E2AEAC><EFBFBD><EFBFBD><EFBFBD>᪠<EFBFBD> <20><>६<EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
12 "<22><>ࠬ<EFBFBD><E0A0AC><EFBFBD> <20>㭪樨 <20><><EFBFBD> auto \"%s%s\" 㦥 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
13 "<22><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
14 "<22><> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>祭<EFBFBD><E7A5AD> <20><> <20>㭪樨 void: %s()"
|
|
|
|
|
15 "var <20><> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> <20><>뫪<EFBFBD><EBABAA>: %s"
|
|
|
|
|
16 "POSIX <20><> <20><><EFBFBD><EFBFBD>᪠<EFBFBD><E1AAA0> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 1 ᨬ<><E1A8AC><EFBFBD><EFBFBD>: %s"
|
|
|
|
|
17 "POSIX <20><> <20><><EFBFBD><EFBFBD>᪠<EFBFBD><E1AAA0> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ਥ<EFBFBD> <20> <20>業<EFBFBD><E6A5AD><EFBFBD><EFBFBD> '#'"
|
|
|
|
|
18 "POSIX <20><> <20><><EFBFBD><EFBFBD>᪠<EFBFBD><E1AAA0> <><E1ABA5><EFBFBD>饥 <20><><EFBFBD>祢<EFBFBD><E7A5A2> <><E1ABAE>: %s"
|
|
|
|
|
19 "POSIX <20><> <20><><EFBFBD><EFBFBD>᪠<EFBFBD><E1AAA0> <20><><EFBFBD><EFBFBD><EFBFBD> ('.') <20> <20><><EFBFBD><EFBFBD><EFBFBD>⢥ <20><><EFBFBD>몠 <20><><EFBFBD> <20><><EFBFBD><E1ABA5><EFBFBD><EFBFBD><EFBFBD> १<><E0A5A7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
20 "POSIX <20>ॡ<EFBFBD><E0A5A1><EFBFBD> <><E1AAAE><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
21 "POSIX <20><> ࠧ<><E0A0A7>蠥<EFBFBD> <20>ᯮ<EFBFBD>짮<EFBFBD><ECA7AE><EFBFBD><EFBFBD> <><E1ABA5><EFBFBD>騩 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>: %s"
|
|
|
|
|
22 "POSIX <20><> ࠧ<><E0A0A7>蠥<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ࠬ <20>ࠢ<EFBFBD><E0A0A2><EFBFBD><EFBFBD><EFBFBD> <20><>室<EFBFBD><E5AEA4><EFBFBD> <20><> <20>।<EFBFBD><E0A5A4><EFBFBD>, <20> <20>⢥ত<E2A2A5><E0A6A4><EFBFBD><EFBFBD> <20><><EFBFBD> 横<><E6A8AA>"
|
|
|
|
|
23 "POSIX <20>ॡ<EFBFBD><E0A5A1><EFBFBD> 0 <20><><EFBFBD> 1 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>ࠢ<EFBFBD><E0A0A2><EFBFBD><EFBFBD><EFBFBD> <20><> <20><EFBFBD><E1ABAE><EFBFBD>"
|
|
|
|
|
24 "POSIX <20>ॡ<EFBFBD><E0A5A1><EFBFBD>, <20>⮡<EFBFBD> <20><><EFBFBD> 3 <20><><EFBFBD><EFBFBD><EFBFBD> <20><>⫨ <20>뫨 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>묨"
|
|
|
|
|
25 "POSIX <20><> <20><><EFBFBD><EFBFBD>᪠<EFBFBD><E1AAA0> <20><>ᯮ<EFBFBD><E1AFAE><EFBFBD>樠<EFBFBD>쭮<EFBFBD> <20><><EFBFBD><EFBFBD>樨"
|
|
|
|
|
26 "POSIX <20><> <20><><EFBFBD><EFBFBD>᪠<EFBFBD><E1AAA0> <20><>뫪<EFBFBD> <20><> <20><><EFBFBD>ᨢ <20> <20><><EFBFBD><EFBFBD><EFBFBD>⢥ <20><>ࠬ<EFBFBD><E0A0AC> <20>㭪樨"
|
|
|
|
|
27 "POSIX <20>ॡ<EFBFBD><E0A5A1><EFBFBD>, <20>⮡<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <><E1AAAE><EFBFBD> <20>뫠 <20><> ⮩ <20><> <20><><EFBFBD><EFBFBD><EFBFBD>, <20><><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>㭪樨"
|
|
|
|
|
|
|
|
|
|
$ <20>訡<EFBFBD><E8A8A1> <20>믮<EFBFBD><EBAFAE><EFBFBD><EFBFBD><EFBFBD><EFBFBD>.
|
|
|
|
|
$set 5
|
|
|
|
|
|
|
|
|
|
1 "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢨⥫<E2A2A8><E2A5AB><EFBFBD><EFBFBD> ibase: <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> [%lu, %lu]"
|
|
|
|
|
2 "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢨⥫<E2A2A8><E2A5AB><EFBFBD><EFBFBD> obase: <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> [%lu, %lu]"
|
|
|
|
|
3 "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢨⥫쭠<E2A5AB> scale: <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD> [%lu, %lu]"
|
|
|
|
|
4 "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢨⥫쭮<E2A5AB> <20><>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD> read()"
|
|
|
|
|
5 "४<><E0A5AA>ᨢ<EFBFBD><E1A8A2><EFBFBD> <20>맮<EFBFBD> read()"
|
|
|
|
|
6 "<22><>६<EFBFBD><E0A5AC><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ᨢ<EFBFBD> <><EFA2AB><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>ࠢ<EFBFBD><E0A0A2><EFBFBD><EFBFBD><EFBFBD><EFBFBD> ⨯<><E2A8AF>"
|
|
|
|
|
7 "<22>⮯<EFBFBD><E2AEAF> <20><><EFBFBD><EFBFBD><EFBFBD> 誮<E1ABA8> <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⮢"
|
|
|
|
|
8 "<22><><EFBFBD>ࠢ<EFBFBD><E0A0A2>쭮<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>⢮ <20><>ࠬ<EFBFBD><E0A0AC>; <20>㦭<EFBFBD> %zu, <20>㦭<EFBFBD> %zu"
|
|
|
|
|
9 "<22><><EFBFBD><EFBFBD>।<EFBFBD><E0A5A4><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>㭪<EFBFBD><E3ADAA><EFBFBD>: %s()"
|
|
|
|
|
10 "<22><> <20><><EFBFBD><EFBFBD><EFBFBD> <20>ᯮ<EFBFBD>짮<EFBFBD><ECA7AE><EFBFBD><EFBFBD> <20><><EFBFBD>⮥ <20><><EFBFBD>祭<EFBFBD><E7A5AD> <20> <20><>ࠦ<EFBFBD><E0A0A6><EFBFBD><EFBFBD>"
|
|
|
|
|
|
|
|
|
|
$ <20><>⠫<EFBFBD><E2A0AB><EFBFBD><EFBFBD> <20>訡<EFBFBD><E8A8A1>.
|
|
|
|
|
$set 6
|
|
|
|
|
|
|
|
|
|
1 "<22><> 㤠<><E3A4A0><EFBFBD><EFBFBD> <20>뤥<EFBFBD><EBA4A5><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>"
|
|
|
|
|
2 "<22>訡<EFBFBD><E8A8A1> <20><><EFBFBD><EFBFBD><EFBFBD>/<2F>뢮<EFBFBD><EBA2AE>"
|
|
|
|
|
3 "<22><> ᬮ<> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 䠩<>: %s"
|
|
|
|
|
4 "䠩<> <20><> ASCII: %s"
|
|
|
|
|
5 "<22><><EFBFBD><EFBFBD> - <20><><EFBFBD> <20><>⠫<EFBFBD><E2A0AB>: %s"
|
|
|
|
|
6 "<22><><EFBFBD><EFBFBD>ୠ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><>ப<EFBFBD>: '%c' (\"%s\")"
|
|
|
|
|
|
|
|
|
|
$set 7
|
|
|
|
|
|
|
|
|
|
1 "<22><><EFBFBD><EFBFBD><EFBFBD> <20>ॡ<EFBFBD><E0A5A1><EFBFBD> <20><><EFBFBD>㬥<EFBFBD><E3ACA5><EFBFBD>: '%c' (\"%s\")"
|
|
|
|
|
2 "<22><><EFBFBD><EFBFBD><EFBFBD> <20><> <20>ਭ<EFBFBD><E0A8AD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD>㬥<EFBFBD>⮢: '%c' (\"%s\")"
|