public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug c/28575] misleading __builtin_choose_expr documentation error [not found] <bug-28575-4@http.gcc.gnu.org/bugzilla/> @ 2010-11-29 18:24 ` przemoc at gmail dot com 2014-03-25 16:30 ` mpolacek at gcc dot gnu.org 1 sibling, 0 replies; 6+ messages in thread From: przemoc at gmail dot com @ 2010-11-29 18:24 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28575 Przemysław Pawełczyk <przemoc at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |przemoc at gmail dot com --- Comment #4 from Przemysław Pawełczyk <przemoc at gmail dot com> 2010-11-29 18:06:57 UTC --- I'm also curious why the trivial fix has not been applied yet. --- a/gcc-4.5.1/gcc/doc/extend.texi 2010-11-29 18:39:21.000000000 +0100 +++ b/gcc-4.5.1/gcc/doc/extend.texi 2010-11-29 18:39:54.000000000 +0100 @@ -7026,7 +7026,7 @@ You can use the built-in function @code{__builtin_choose_expr} to evaluate code depending on the value of a constant expression. This built-in function returns @var{exp1} if @var{const_exp}, which is an -integer constant expression, is nonzero. Otherwise it returns 0. +integer constant expression, is nonzero. Otherwise it returns @var{exp2}. This built-in function is analogous to the @samp{? :} operator in C, except that the expression returned has its type unaltered by promotion ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/28575] misleading __builtin_choose_expr documentation error [not found] <bug-28575-4@http.gcc.gnu.org/bugzilla/> 2010-11-29 18:24 ` [Bug c/28575] misleading __builtin_choose_expr documentation error przemoc at gmail dot com @ 2014-03-25 16:30 ` mpolacek at gcc dot gnu.org 1 sibling, 0 replies; 6+ messages in thread From: mpolacek at gcc dot gnu.org @ 2014-03-25 16:30 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28575 Marek Polacek <mpolacek at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |mpolacek at gcc dot gnu.org Resolution|--- |FIXED --- Comment #5 from Marek Polacek <mpolacek at gcc dot gnu.org> --- This was fixed in r163675. ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug web/28575] New: misleading __builtin_choose_expr documentation error @ 2006-08-02 18:45 twang at apple dot com 2006-08-02 18:49 ` [Bug c/28575] " pinskia at gcc dot gnu dot org ` (3 more replies) 0 siblings, 4 replies; 6+ messages in thread From: twang at apple dot com @ 2006-08-02 18:45 UTC (permalink / raw) To: gcc-bugs This documentation error exists for all versions of gcc-3.*, gcc-4.* documentation. Relevant links are http://gcc.gnu.org/onlinedocs/gcc-4.1.1/gcc/Other-Builtins.html http://gcc.gnu.org/onlinedocs/gcc-4.0.3/gcc/Other-Builtins.html The error text is: Built-in Function: type __builtin_choose_expr (const_exp, exp1, exp2) You can use the built-in function __builtin_choose_expr to evaluate code depending on the value of a constant expression. This built-in function returns exp1 if const_exp, which is a constant expression that must be able to be determined at compile time, is nonzero. --> Otherwise it returns 0. should be --> Otherwise it returns exp2. This is confusing and misleading for the actual functionailty of the builtin, it shold be changed. -- Summary: misleading __builtin_choose_expr documentation error Product: gcc Version: 4.0.1 Status: UNCONFIRMED Severity: minor Priority: P3 Component: web AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: twang at apple dot com GCC build triplet: powerpc-apple-darwin8 GCC host triplet: powerpc-apple-darwin8 GCC target triplet: powerpc-apple-darwin8 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28575 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/28575] misleading __builtin_choose_expr documentation error 2006-08-02 18:45 [Bug web/28575] New: " twang at apple dot com @ 2006-08-02 18:49 ` pinskia at gcc dot gnu dot org 2006-08-02 18:51 ` pinskia at gcc dot gnu dot org ` (2 subsequent siblings) 3 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu dot org @ 2006-08-02 18:49 UTC (permalink / raw) To: gcc-bugs -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |aldyh at gcc dot gnu dot org Severity|minor |enhancement Component|web |c GCC build triplet|powerpc-apple-darwin8 | GCC host triplet|powerpc-apple-darwin8 | GCC target triplet|powerpc-apple-darwin8 | Keywords| |documentation http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28575 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/28575] misleading __builtin_choose_expr documentation error 2006-08-02 18:45 [Bug web/28575] New: " twang at apple dot com 2006-08-02 18:49 ` [Bug c/28575] " pinskia at gcc dot gnu dot org @ 2006-08-02 18:51 ` pinskia at gcc dot gnu dot org 2007-09-10 15:49 ` brian at oddchange dot com 2008-04-24 15:05 ` vincent at vinc17 dot org 3 siblings, 0 replies; 6+ messages in thread From: pinskia at gcc dot gnu dot org @ 2006-08-02 18:51 UTC (permalink / raw) To: gcc-bugs ------- Comment #1 from pinskia at gcc dot gnu dot org 2006-08-02 18:50 ------- Confirmed. This has been an issue since the function was added. -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Last reconfirmed|0000-00-00 00:00:00 |2006-08-02 18:50:58 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28575 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/28575] misleading __builtin_choose_expr documentation error 2006-08-02 18:45 [Bug web/28575] New: " twang at apple dot com 2006-08-02 18:49 ` [Bug c/28575] " pinskia at gcc dot gnu dot org 2006-08-02 18:51 ` pinskia at gcc dot gnu dot org @ 2007-09-10 15:49 ` brian at oddchange dot com 2008-04-24 15:05 ` vincent at vinc17 dot org 3 siblings, 0 replies; 6+ messages in thread From: brian at oddchange dot com @ 2007-09-10 15:49 UTC (permalink / raw) To: gcc-bugs ------- Comment #2 from brian at oddchange dot com 2007-09-10 15:49 ------- *** Bug 33013 has been marked as a duplicate of this bug. *** -- brian at oddchange dot com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |brian at oddchange dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28575 ^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug c/28575] misleading __builtin_choose_expr documentation error 2006-08-02 18:45 [Bug web/28575] New: " twang at apple dot com ` (2 preceding siblings ...) 2007-09-10 15:49 ` brian at oddchange dot com @ 2008-04-24 15:05 ` vincent at vinc17 dot org 3 siblings, 0 replies; 6+ messages in thread From: vincent at vinc17 dot org @ 2008-04-24 15:05 UTC (permalink / raw) To: gcc-bugs ------- Comment #3 from vincent at vinc17 dot org 2008-04-24 15:04 ------- Is there any reason why this hasn't been fixed yet? (The trunk still has the error. And I'm asking this because there's only one word to change.) -- vincent at vinc17 dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |vincent at vinc17 dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28575 ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2014-03-25 16:30 UTC | newest] Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- [not found] <bug-28575-4@http.gcc.gnu.org/bugzilla/> 2010-11-29 18:24 ` [Bug c/28575] misleading __builtin_choose_expr documentation error przemoc at gmail dot com 2014-03-25 16:30 ` mpolacek at gcc dot gnu.org 2006-08-02 18:45 [Bug web/28575] New: " twang at apple dot com 2006-08-02 18:49 ` [Bug c/28575] " pinskia at gcc dot gnu dot org 2006-08-02 18:51 ` pinskia at gcc dot gnu dot org 2007-09-10 15:49 ` brian at oddchange dot com 2008-04-24 15:05 ` vincent at vinc17 dot org
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).