Commit Graph

228 Commits

Author SHA1 Message Date
Laytan Laats
e2cecafa66 allow integer verbs in fmt_bit_set 2023-11-07 21:09:42 +01:00
gingerBill
e206d6ba35 Add allocator parameter to fmt's aprint and aprintln 2023-11-03 13:26:33 +00:00
Jeroen van Rijn
1287e8c734 Merge pull request #2839 from Tetralux/aprintf-ally
[fmt] Add allocator parameter to `fmt.aprintf`
2023-10-02 11:23:26 +02:00
Tetralux
7a6ac3ea92 [fmt] Add allocator parameter to fmt.aprintf
This allows you to do `fmt.aprintf("Hello, %v!", name, allocator = ally)`.
2023-10-02 02:46:26 +00:00
gingerBill
14adcb9db8 Use or_break and or_continue where appropriate in the core library 2023-09-30 15:34:39 +01:00
Laytan Laats
d47b0eeee7 update doc 2023-09-12 16:51:21 +02:00
Laytan Laats
287beaff35 use KiB etc. instead of KB 2023-09-12 16:49:42 +02:00
Laytan Laats
735cfcd290 Add formatting of bytes into the best unit of measurement 2023-09-01 19:17:07 +02:00
gingerBill
515163864f Add optional flush := true to many of the core:fmt procedures 2023-08-22 17:24:12 +01:00
gingerBill
49ab935ae9 Disallow for in in favour of for _ in 2023-08-08 14:56:12 +01:00
gingerBill
c91898a888 Remove #relative slices; Replace with #relative multi-pointers 2023-08-05 16:05:39 +01:00
gingerBill
44ea82f845 Clean up usage of using throughout core and vendor 2023-07-31 11:46:40 +01:00
gingerBill
6c6f9f7d25 Fix fmt implementation for js 2023-06-26 15:55:35 +01:00
gingerBill
19ea090633 Merge pull request #2584 from odin-lang/new-io
New and Improved `io.Stream` interface
2023-06-23 12:12:17 +01:00
gingerBill
9b54b99bf6 Use positional and named arguments within the core library 2023-06-21 01:17:05 +01:00
gingerBill
9ee4b76cd9 Just make the io.Reader etc aliases 2023-06-08 16:38:57 +01:00
gingerBill
ae7bf468d1 Merge pull request #2573 from inbelic/inbelic/fmt-zero-padding
[fmt] fix zero-padding behaviour of numbers
2023-06-07 11:44:53 +01:00
gingerBill
d6f45e4d76 Fix fmt for js 2023-06-06 22:38:43 +01:00
gingerBill
0defd1d141 Correct printing in fmt for ODIN_ERROR_POS_STYLE 2023-06-06 11:17:34 +01:00
finn
6952124988 [fmt] fix zero-padding behaviour of numbers
- when formatting a negative number with left zero-padding we expect the
  padding to be placed between the minus (-) sign and the number
- currently the padding is placed before the sign
2023-06-01 16:04:07 +02:00
gingerBill
32ca50a097 Fix special printing for certain named types with fmt.printf related procedures 2023-05-24 20:54:30 +01:00
gingerBill
023cc9ca54 Partially buffer fmt.fprint* related calls using a bufio.Writer 2023-04-27 00:24:00 +01:00
Jeroen van Rijn
7ffca8ed58 Fix caprintf comment 2023-03-27 11:12:21 +02:00
Jeroen van Rijn
030405dbb6 Update fmt.odin
Fix hardcoded 64 bit, use assert instead of branched panic.
2023-03-27 11:06:29 +02:00
jon lipstate
34b037f19b Update fmt.odin
Update example to use set/register procs.
2023-03-26 11:23:37 -07:00
Jon Lipstate
0892d84c17 corrected bprint 2023-03-25 23:55:37 -07:00
Jon Lipstate
2501d50f9c fmt docs 2023-03-25 23:45:53 -07:00
WraithGlade
adcc865c70 Fixed incorrect precision value in fmt doc.
It seems like `%.2f` is the correct implementation of "precision 2" for displaying floats, not `$.3f`. It prints two decimal places.

Either that or the next case (`%8.3f`) would be wrong instead, if it's the other way around. 

So, there's a mistake here one way or the other at the least.
2023-03-19 22:06:39 -04:00
gingerBill
6179d4feb1 Rename to Type_Info_Parameters 2023-02-08 11:23:21 +00:00
MarenFayre
fd4633eb25 Clean up float_fmt logic 2023-01-10 15:03:53 +01:00
gingerBill
b0756f9e29 Merge pull request #2297 from MarenFayre/d-parsing
Fix off by one error in %d parsing
2023-01-10 12:24:13 +00:00
MarenFayre
13029d06b2 Removed unneeded semicolon. 2023-01-09 10:39:46 +01:00
MarenFayre
c979c2fafa Fix left padding format specifier and float formatting 2023-01-08 20:00:42 +01:00
MarenFayre
658435f1b9 Fix off by one error in %d parsing 2023-01-08 19:59:48 +01:00
thisisnotnull
76b85c0622 fix wprintf return value 2022-11-21 21:39:43 +01:00
gingerBill
ed58374964 Make Map_Info store pointers to cell info rather than inline 2022-11-08 12:18:36 +00:00
gingerBill
50e10ceb3b Correct hashing for map types 2022-11-08 01:20:08 +00:00
gingerBill
da774e3fd2 General modifications 2022-11-08 00:38:31 +00:00
gingerBill
2c3febd620 Correct fmt printing to be robust 2022-11-07 23:35:44 +00:00
gingerBill
bce62b98d4 Basic fmt printing for map 2022-11-07 23:32:59 +00:00
gingerBill
c96e0afbf1 Begin work on implementing the new map internals 2022-11-07 23:02:21 +00:00
gingerBill
30db316e16 Merge pull request #2141 from ChuuniMage/patch-2
Add caprintf and ctprintf to fmt
2022-11-03 12:57:46 +00:00
Jeroen van Rijn
22672a816e Merge pull request #2153 from oskarnp/fix-fmt-string-width
Fix behavior of fmt_string() to not truncate strings to width
2022-10-26 17:54:26 +02:00
Oskar Nordquist
dcb873c88d Fix behavior of fmt_string() to not truncate strings to width 2022-10-26 11:21:42 -04:00
nowheredevel
4389059834 Fix printf typo in documentation 2022-10-25 19:06:15 -04:00
ChuuniMage
9dee943fae Update fmt.odin
Feedback regarding internal `fmt` reference addressed
2022-10-21 14:50:46 +11:00
ChuuniMage
a459bc13dc Add caprintf and ctprintf to fmt
Formatted cstring procs to work with ubiquitous cstring APIs
2022-10-21 10:23:10 +11:00
gingerBill
f50fc33749 Clean up of the core library to make the stream vtables not be pointers directly. 2022-09-15 10:00:50 +01:00
gingerBill
c9eed04b51 Add comment regarding the layout of a map to explain how it is iterated 2022-08-26 16:19:48 +01:00
gingerBill
60aeab3c38 Update fmt.odin 2022-08-08 15:07:19 +01:00