<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/src/libcore/fmt, branch 1.12.1</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=1.12.1</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=1.12.1'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2016-08-13T13:37:09+00:00</updated>
<entry>
<title>Rename empty/bang to never</title>
<updated>2016-08-13T13:37:09+00:00</updated>
<author>
<name>Andrew Cann</name>
<email>shum@canndrew.org</email>
</author>
<published>2016-08-02T07:56:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=fadabe08f52ce524a0cbb5af327e55db61198024'/>
<id>urn:sha1:fadabe08f52ce524a0cbb5af327e55db61198024</id>
<content type='text'>
Split Ty::is_empty method into is_never and is_uninhabited
</content>
</entry>
<entry>
<title>Minor fixups based on @eddyb's feedback</title>
<updated>2016-08-13T13:37:09+00:00</updated>
<author>
<name>Andrew Cann</name>
<email>shum@canndrew.org</email>
</author>
<published>2016-08-02T05:46:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=f0a8b6d43f26907ac7d7abc35510878f61551fbf'/>
<id>urn:sha1:f0a8b6d43f26907ac7d7abc35510878f61551fbf</id>
<content type='text'>
Mainly, remove mk_empty() method and replace with tcx.types.empty
</content>
</entry>
<entry>
<title>impl Debug + Display for !</title>
<updated>2016-08-13T13:37:09+00:00</updated>
<author>
<name>Andrew Cann</name>
<email>shum@canndrew.org</email>
</author>
<published>2016-07-30T05:24:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=ee78f37e2a68120119dcda4312db0be3b545eabe'/>
<id>urn:sha1:ee78f37e2a68120119dcda4312db0be3b545eabe</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Rename `char::escape` to `char::escape_debug` and add tracking issue</title>
<updated>2016-07-28T00:20:49+00:00</updated>
<author>
<name>Tobias Bucher</name>
<email>tobiasbucher5991@gmail.com</email>
</author>
<published>2016-07-27T10:10:31+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=3d09b4a0d58200da84fe19cd3b0003d61e5b1791'/>
<id>urn:sha1:3d09b4a0d58200da84fe19cd3b0003d61e5b1791</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Restore `char::escape_default` and add `char::escape` instead</title>
<updated>2016-07-26T13:15:00+00:00</updated>
<author>
<name>Tobias Bucher</name>
<email>tobiasbucher5991@gmail.com</email>
</author>
<published>2016-07-25T23:39:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=68efea08fa1cf800b3b76683992ec77a89323d53'/>
<id>urn:sha1:68efea08fa1cf800b3b76683992ec77a89323d53</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Auto merge of #34544 - 3Hren:issue/xx/reinterpret-format-precision-for-strings, r=alexcrichton</title>
<updated>2016-07-21T23:19:54+00:00</updated>
<author>
<name>bors</name>
<email>bors@rust-lang.org</email>
</author>
<published>2016-07-21T23:19:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=62690b3c3fa6e157daa7f7c5a3af005f37eb4199'/>
<id>urn:sha1:62690b3c3fa6e157daa7f7c5a3af005f37eb4199</id>
<content type='text'>
feat: reinterpret `precision` field for strings

This commit changes the behavior of formatting string arguments with both width and precision fields set.

Documentation says that the `width` field is the "minimum width" that the format should take up. If the value's string does not fill up this many characters, then the padding specified by fill/alignment will be used to take up the required space.

This is true for all formatted types except string, which is truncated down to `precision` number of chars and then all of `fill`, `align` and `width` fields are completely ignored.

For example: `format!("{:/^10.8}", "1234567890);` emits "12345678". In the contrast Python version works as the expected:
```python
&gt;&gt;&gt; '{:/^10.8}'.format('1234567890')
'/12345678/'
```

This commit gives back the `Python` behavior by changing the `precision` field meaning to the truncation and nothing more. The result string *will* be prepended/appended up to the `width` field with the proper `fill` char.

__However, this is the breaking change, I admit.__ Feel free to close it, but otherwise it should be mentioned in the `std::fmt` documentation somewhere near of `fill/align/width` fields description.
</content>
</entry>
<entry>
<title>feat: reinterpret `precision` field for strings</title>
<updated>2016-07-05T21:01:14+00:00</updated>
<author>
<name>Evgeny Safronov</name>
<email>division494@gmail.com</email>
</author>
<published>2016-06-29T07:40:25+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=ede39aeb331bf6efb3739d22a60c1844e9c2c3d6'/>
<id>urn:sha1:ede39aeb331bf6efb3739d22a60c1844e9c2c3d6</id>
<content type='text'>
This commit changes the behavior of formatting string arguments
with both width and precision fields set.

Documentation says that the `width` field is the "minimum width"
that the format should take up. If the value's string does not
fill up this many characters, then the padding specified by
fill/alignment will be used to take up the required space.

This is true for all formatted types except string, which is truncated
down to `precision` number of chars and then all of `fill`, `align` and
`width` fields are completely ignored.

For example: `format!("{:/^10.8}", "1234567890);` emits "12345678".
In the contrast Python version works as the expected:
```python
&gt;&gt;&gt; '{:/^10.8}'.format('1234567890')
'/12345678/'
```

This commit gives back the `Python` behavior by changing the `precision`
field meaning to the truncation and nothing more. The result string *will*
be prepended/appended up to the `width` field with the proper `fill` char.

However, this is the breaking change.

Also updated `std::fmt` docs about string precision.

Signed-off-by: Evgeny Safronov &lt;division494@gmail.com&gt;
</content>
</entry>
<entry>
<title>prefer `if let` to match with `None =&gt; {}` arm in some places</title>
<updated>2016-07-03T23:27:02+00:00</updated>
<author>
<name>Zack M. Davis</name>
<email>code@zackmdavis.net</email>
</author>
<published>2016-07-03T21:38:37+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d37edef9dd088d953c5e272db37686a338c31778'/>
<id>urn:sha1:d37edef9dd088d953c5e272db37686a338c31778</id>
<content type='text'>
This is a spiritual succesor to #34268/8531d581, in which we replaced a
number of matches of None to the unit value with `if let` conditionals
where it was judged that this made for clearer/simpler code (as would be
recommended by Manishearth/rust-clippy's `single_match` lint). The same
rationale applies to matches of None to the empty block.
</content>
</entry>
<entry>
<title>Use `len` instead of `size_hint` where appropiate</title>
<updated>2016-06-23T10:26:15+00:00</updated>
<author>
<name>Tobias Bucher</name>
<email>tobiasbucher5991@gmail.com</email>
</author>
<published>2016-06-23T10:26:15+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=8ff5c4394cdfc11f29de36123a6c9618e12c9904'/>
<id>urn:sha1:8ff5c4394cdfc11f29de36123a6c9618e12c9904</id>
<content type='text'>
This makes it clearer that we're not just looking for a lower bound but
rather know that the iterator is an `ExactSizeIterator`.
</content>
</entry>
<entry>
<title>Auto merge of #33460 - shepmaster:16-bit-pointers, r=Aatch</title>
<updated>2016-06-04T05:32:15+00:00</updated>
<author>
<name>bors</name>
<email>bors@rust-lang.org</email>
</author>
<published>2016-06-04T05:32:15+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=7738479d72418ddc08febee0fa7097df334d357e'/>
<id>urn:sha1:7738479d72418ddc08febee0fa7097df334d357e</id>
<content type='text'>
Support 16-bit pointers as well as i/usize

I'm opening this pull request to get some feedback from the community.

Although Rust doesn't support any platforms with a native 16-bit pointer at the moment, the [AVR-Rust][ar] fork is working towards that goal. Keeping this forked logic up-to-date with the changes in master has been onerous so I'd like to merge these changes so that they get carried along when refactoring happens. I do not believe this should increase the maintenance burden.

This is based on the original work of Dylan McKay (@dylanmckay).

[ar]: https://github.com/avr-rust/rust
</content>
</entry>
</feed>
