Jeong YunWon
ff4efd0f60
Fix unnessessary borrow
2021-07-30 02:32:16 +09:00
Noah
18492e6a20
Remove pystr::{borrow,clone}_value
2021-05-20 18:45:03 -05:00
Noah
99104faaf7
Re-export pyobject::* from the root of the crate
2021-05-20 10:24:07 -05:00
Noah
f50f930255
Add setattro slot, split call_method and call_special_method
2021-03-15 09:45:06 -05:00
ChJR
4f1232a0c2
Fix error of CI
2020-11-20 02:41:44 +09:00
ChJR
213a335bcf
Unify fixed-point format of floating numbers
2020-11-10 02:42:46 +09:00
ChJR
8c96bd680f
Unify general format of floating numbers
2020-11-10 01:56:08 +09:00
ChJR
e95469e1c5
Refine names for shorter code
2020-11-10 01:32:54 +09:00
ChJR
db976ddc70
Clear up format_float_as_exponent
2020-11-10 00:57:32 +09:00
ChJR
dc3a30066b
Unify format_float_as_exponent to clarify
2020-10-31 22:58:46 +09:00
ChJR
3838610e55
Fix fmt check
2020-10-26 23:58:51 +09:00
ChJR
edc4de20e4
Remove not matched comments
2020-10-26 23:48:28 +09:00
ChJR
3344ae17cf
Fix default format(float) result when the number is too big
...
Before this change, format(1e16) returns '10000000000000000.0' in RustPython while CPython 3.7 returns '1e+16'.
After this change, format(1e16) returns '1e+16' in RustPython too.
2020-10-26 00:27:14 +09:00
Jeong YunWon
19ed4f85e7
clean up vm::builtins
2020-10-13 15:42:11 +09:00
Jeong YunWon
9e6dfca9e9
Fix build with new builtins path
2020-10-11 21:16:16 +09:00
Jeong YunWon
4da1b62c18
PyFuncArgs -> FuncArgs
...
which does not represent a single python object
2020-10-11 09:38:07 +09:00
Jeong YunWon
b0445396f4
compactize invoke args
2020-10-11 09:38:06 +09:00
Jeong YunWon
a089c9b6d3
TypeProcotol::lease_class() -> TypeProtocol::class()
2020-10-11 09:11:58 +09:00
Jeong YunWon
fe5767a975
lease_class as much as possible
2020-09-30 11:41:06 +09:00
Jeong YunWon
bd3d4cfdb2
earlier returning for error
2020-08-23 06:54:25 +09:00
Jeong YunWon
f45d2f03ef
avoid to_pystr to generate type name
2020-08-14 02:34:36 +09:00
Jeong YunWon
a197fc0af1
move instead of ref for format_internal
2020-08-09 23:56:29 +09:00
Jeong YunWon
9f8e2af123
impl IntoPyException for FormatParseError
2020-08-05 23:15:35 +09:00
Jeong YunWon
ea25947b53
Remove impl IntoPyObject for &PyObjectRef and &PyRef
...
they doesn't give any benefit but just hide clone
2020-08-05 14:17:01 +09:00
Jeong YunWon
61455ce261
Separate IntoPyObject and IntoPyResult
2020-08-04 22:59:34 +09:00
Ben Lewis
928bca88c6
Code review changes.
2020-08-02 07:37:47 +12:00
Ben Lewis
e9a2944138
Fix clippy warnings
2020-08-02 07:22:05 +12:00
Ben Lewis
1c18d99044
Run rustfmt
2020-08-02 07:22:05 +12:00
Ben Lewis
058e73a376
Fix compilation of rust unit tests.
2020-08-02 07:22:05 +12:00
Ben Lewis
fa3e571889
Unmark tests that are now passing in test_unicode.py.
2020-08-02 07:22:05 +12:00
Ben Lewis
8ae65dad76
Fix bug in format auto spec indexing.
2020-08-02 07:22:05 +12:00
Ben Lewis
e90e2bfc6e
Implement string module.
2020-08-02 07:22:05 +12:00
Ben Lewis
c4ddff84ce
Implement "{x.attr}".format(...).
2020-08-02 07:22:05 +12:00
Jeong YunWon
1b2d179b38
Add string typed formatting
2020-07-23 06:06:13 +09:00
Jeong YunWon
a0a73e5d97
format.rs owns related code
2020-07-23 06:06:13 +09:00
Antonio Yang
bf9eb7a1b0
update testcase
2020-07-18 21:26:48 +08:00
Antonio Yang
ec42059dcb
build spec of format when parse
2020-07-18 21:16:58 +08:00
Noah
dd92e90366
Add str.__format__
2020-04-02 17:42:00 -05:00
Abe
4c72a3c853
Implement format code e & E for floats and ints
2020-03-06 18:12:48 -07:00
Jeong YunWon
7d0d313aa5
&str::to_string -> &str::to_owned for variables
2020-02-05 22:55:34 +09:00
Jeong YunWon
1bac582921
&str::to_string -> &str::to_owned for literals
2020-02-05 22:55:33 +09:00
Jeong YunWon
1c2b01f894
parse_number can raise error about length
2020-02-01 21:29:01 +09:00
Abe
6a1580141b
Implement the '%' string format code for integers
2020-01-04 19:54:54 -07:00
Abe
765089d560
Add support for the % format code for floats.
...
Contributes to #1656
2020-01-03 16:14:24 -07:00
Abe
30473d3058
Add support for string formatting of floats with ":f" format code
...
Also adds automatic conversion of int -> float when the ":f"
format code is specified.
Fixes a f-string formatting style regression introduced in #1625 .
2019-12-31 18:52:46 -07:00
Jeong YunWon
c1306726c4
Fix clippy warnings
2019-12-21 18:49:48 +09:00
yanganto
10ef5e56af
bytes.mod implement mod
...
implement byte formatting with CFormat
2019-11-18 08:39:36 +08:00
lazylife7157
b1482d6318
Fix magnitude seperator format bug
2019-10-06 21:14:09 +09:00
j30ng
3768233c8e
Enable Zero-padding with Format Strings
2019-09-28 00:36:48 +09:00
Maxim Kurnikov
347d48198e
fix remaining clippy warnings
2019-07-07 06:27:07 +03:00