<feed xmlns='http://www.w3.org/2005/Atom'>
<title>clang/lib/Analysis/FormatString.cpp, branch release-3.2</title>
<subtitle>Unofficial clang GIT mirror used in EmbToolkit
</subtitle>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/'/>
<entry>
<title>Format strings: offer a fixit for Darwin's %D/%U/%O to ISO %d/%u/%o.</title>
<updated>2012-09-13T02:11:15+00:00</updated>
<author>
<name>Jordan Rose</name>
<email>jordan_rose@apple.com</email>
</author>
<published>2012-09-13T02:11:15+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=670941c28c0683ecc251dafdf093a71629625dc9'/>
<id>670941c28c0683ecc251dafdf093a71629625dc9</id>
<content type='text'>
&lt;rdar://problem/12061922&gt;

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163772 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
&lt;rdar://problem/12061922&gt;

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163772 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Format strings: %D, %U, and %O are valid on Darwin (same as %d, %u, %o).</title>
<updated>2012-09-13T02:11:03+00:00</updated>
<author>
<name>Jordan Rose</name>
<email>jordan_rose@apple.com</email>
</author>
<published>2012-09-13T02:11:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=275b6f52c7bcafc1f3cf291813b5c60ee776965a'/>
<id>275b6f52c7bcafc1f3cf291813b5c60ee776965a</id>
<content type='text'>
These will warn under -Wformat-non-iso, and will still be rejected
outright on other platforms.

&lt;rdar://problem/12061922&gt;

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163771 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These will warn under -Wformat-non-iso, and will still be rejected
outright on other platforms.

&lt;rdar://problem/12061922&gt;

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163771 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Format strings: suggest %lld instead of %qd and %Ld with -Wformat-non-iso.</title>
<updated>2012-09-08T04:00:12+00:00</updated>
<author>
<name>Jordan Rose</name>
<email>jordan_rose@apple.com</email>
</author>
<published>2012-09-08T04:00:12+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=8be066e6733364cd34f25c4f7b7344f72aa23369'/>
<id>8be066e6733364cd34f25c4f7b7344f72aa23369</id>
<content type='text'>
As a corollary to the previous commit, even when an extension is
available, we can still offer a fixit to the standard modifier.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163453 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As a corollary to the previous commit, even when an extension is
available, we can still offer a fixit to the standard modifier.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163453 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Format strings: %Ld isn't available on Darwin or Windows.</title>
<updated>2012-09-08T04:00:03+00:00</updated>
<author>
<name>Jordan Rose</name>
<email>jordan_rose@apple.com</email>
</author>
<published>2012-09-08T04:00:03+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=bbb6bb4952b77e57b842b4d3096848123ae690e7'/>
<id>bbb6bb4952b77e57b842b4d3096848123ae690e7</id>
<content type='text'>
This seems to be a GNU libc extension; we offer a fixit to %lld on
these platforms.

&lt;rdar://problem/11518237&gt;

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163452 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This seems to be a GNU libc extension; we offer a fixit to %lld on
these platforms.

&lt;rdar://problem/11518237&gt;

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163452 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove ScanfArgType and bake that logic into ArgType.</title>
<updated>2012-08-07T08:59:46+00:00</updated>
<author>
<name>Hans Wennborg</name>
<email>hans@hanshq.net</email>
</author>
<published>2012-08-07T08:59:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=58e1e54476d610d6c33ef483f216ed8a1282d35c'/>
<id>58e1e54476d610d6c33ef483f216ed8a1282d35c</id>
<content type='text'>
This is useful for example for %n in printf, which expects
a pointer to int with the same logic for checking as %d
would have in scanf.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161407 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is useful for example for %n in printf, which expects
a pointer to int with the same logic for checking as %d
would have in scanf.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161407 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Rename analyze_format_string::ArgTypeResult to ArgType</title>
<updated>2012-08-07T08:11:26+00:00</updated>
<author>
<name>Hans Wennborg</name>
<email>hans@hanshq.net</email>
</author>
<published>2012-08-07T08:11:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=f3749f4168c5cee59627a681ca4ca6e4116d0761'/>
<id>f3749f4168c5cee59627a681ca4ca6e4116d0761</id>
<content type='text'>
Also remove redundant constructors and unused member functions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161403 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Also remove redundant constructors and unused member functions.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161403 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>-Wformat: better handling of qualifiers on pointer arguments</title>
<updated>2012-07-31T16:37:47+00:00</updated>
<author>
<name>Hans Wennborg</name>
<email>hans@hanshq.net</email>
</author>
<published>2012-07-31T16:37:47+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=5deddafd3ef51e94b4ac4d80e38271d3768b1af6'/>
<id>5deddafd3ef51e94b4ac4d80e38271d3768b1af6</id>
<content type='text'>
Warn about using pointers to const-qualified types as arguments to
scanf. Ignore the volatile qualifier when checking if types match.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161052 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Warn about using pointers to const-qualified types as arguments to
scanf. Ignore the volatile qualifier when checking if types match.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@161052 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Make -Wformat walk the typedef chain when looking for size_t, etc.</title>
<updated>2012-07-27T19:17:46+00:00</updated>
<author>
<name>Hans Wennborg</name>
<email>hans@hanshq.net</email>
</author>
<published>2012-07-27T19:17:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=4684778993c667246039b4664acbce59dc99440c'/>
<id>4684778993c667246039b4664acbce59dc99440c</id>
<content type='text'>
Clang's -Wformat fix-its currently suggest using "%zu" for values of
type size_t (in C99 or C++11 mode). However, for a type such as
std::vector&lt;T&gt;::size_type, it does not notice that type is actually
typedeffed to size_t, and instead suggests a format for the underlying
type, such as "%lu" or "%u".

This commit makes the format string fix mechanism walk the typedef chain
so that it notices if the type is size_t, even if that isn't "at the
top".

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@160886 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Clang's -Wformat fix-its currently suggest using "%zu" for values of
type size_t (in C99 or C++11 mode). However, for a type such as
std::vector&lt;T&gt;::size_type, it does not notice that type is actually
typedeffed to size_t, and instead suggests a format for the underlying
type, such as "%lu" or "%u".

This commit makes the format string fix mechanism walk the typedef chain
so that it notices if the type is size_t, even if that isn't "at the
top".

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@160886 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Teach printf/scanf about enums with fixed underlying types.</title>
<updated>2012-06-04T22:48:57+00:00</updated>
<author>
<name>Jordan Rose</name>
<email>jordan_rose@apple.com</email>
</author>
<published>2012-06-04T22:48:57+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=ee0259d308e72141982a85b40863e760a8447edf'/>
<id>ee0259d308e72141982a85b40863e760a8447edf</id>
<content type='text'>
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@157961 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@157961 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
<entry>
<title>Make -Wformat accept printf("%hhx", c); with -funsigned-char</title>
<updated>2012-05-08T17:21:31+00:00</updated>
<author>
<name>Hans Wennborg</name>
<email>hans@hanshq.net</email>
</author>
<published>2012-05-08T17:21:31+00:00</published>
<link rel='alternate' type='text/html' href='http://git.embtoolkit.org/clang/commit/?id=101d4e0c8ffbcdaaa58cddf1c20f98aa1b4501c4'/>
<id>101d4e0c8ffbcdaaa58cddf1c20f98aa1b4501c4</id>
<content type='text'>
For "%hhx", printf expects an unsigned char. This makes Clang
accept a 'char' argument for that also when using -funsigned-char.

This fixes PR12761.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156388 91177308-0d34-0410-b5e6-96231b3b80d8
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
For "%hhx", printf expects an unsigned char. This makes Clang
accept a 'char' argument for that also when using -funsigned-char.

This fixes PR12761.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@156388 91177308-0d34-0410-b5e6-96231b3b80d8
</pre>
</div>
</content>
</entry>
</feed>
