public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/62314] New: Fix-it Hints
@ 2014-08-30 17:19 manu at gcc dot gnu.org
2014-08-30 17:24 ` [Bug c++/62314] " manu at gcc dot gnu.org
2015-09-10 20:35 ` dmalcolm at gcc dot gnu.org
0 siblings, 2 replies; 3+ messages in thread
From: manu at gcc dot gnu.org @ 2014-08-30 17:19 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62314
Bug ID: 62314
Summary: Fix-it Hints
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: enhancement
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: manu at gcc dot gnu.org
Created attachment 33421
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=33421&action=edit
fixit-hints draft implementation
Quoting from http://clang.llvm.org/diagnostics.html
"Fix-it" hints provide advice for fixing small, localized problems in source
code. When Clang produces a diagnostic about a particular problem that it can
work around (e.g., non-standard or redundant syntax, missing keywords, common
mistakes, etc.), it may also provide specific guidance in the form of a code
transformation to correct the problem.
$ clang t.cpp
t.cpp:9:3: error: template specialization requires 'template<>'
struct iterator_traits<file_iterator> {
^
template<>
The attached patch implements the same behavior for GCC when given
-fdiagnostic-show-caret. When the caret is disabled, it gives:
t.cpp:9:3: error: template specialization requires 'template<>'
t.cpp:9:3: fixit: template<>
so an IDE might parse the "fixit:" diagnostic and use the message to edit the
text directly.
This is work in progress I have not even tried to build gcc using this patch.
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c++/62314] Fix-it Hints
2014-08-30 17:19 [Bug c++/62314] New: Fix-it Hints manu at gcc dot gnu.org
@ 2014-08-30 17:24 ` manu at gcc dot gnu.org
2015-09-10 20:35 ` dmalcolm at gcc dot gnu.org
1 sibling, 0 replies; 3+ messages in thread
From: manu at gcc dot gnu.org @ 2014-08-30 17:24 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62314
--- Comment #1 from Manuel López-Ibáñez <manu at gcc dot gnu.org> ---
There are other examples here:
http://clang.llvm.org/docs/InternalsManual.html#fix-it-hints
>From gcc-bugs-return-459553-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sat Aug 30 18:47:47 2014
Return-Path: <gcc-bugs-return-459553-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org>
Delivered-To: listarch-gcc-bugs@gcc.gnu.org
Received: (qmail 3449 invoked by alias); 30 Aug 2014 18:47:47 -0000
Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm
Precedence: bulk
List-Id: <gcc-bugs.gcc.gnu.org>
List-Archive: <http://gcc.gnu.org/ml/gcc-bugs/>
List-Post: <mailto:gcc-bugs@gcc.gnu.org>
List-Help: <mailto:gcc-bugs-help@gcc.gnu.org>
Sender: gcc-bugs-owner@gcc.gnu.org
Delivered-To: mailing list gcc-bugs@gcc.gnu.org
Received: (qmail 3374 invoked by uid 55); 30 Aug 2014 18:47:42 -0000
From: "burnus at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug fortran/44735] ICE on FORALL with character array pointer
Date: Sat, 30 Aug 2014 18:47:00 -0000
X-Bugzilla-Reason: CC
X-Bugzilla-Type: changed
X-Bugzilla-Watch-Reason: None
X-Bugzilla-Product: gcc
X-Bugzilla-Component: fortran
X-Bugzilla-Version: 4.6.0
X-Bugzilla-Keywords: ice-on-valid-code
X-Bugzilla-Severity: normal
X-Bugzilla-Who: burnus at gcc dot gnu.org
X-Bugzilla-Status: NEW
X-Bugzilla-Priority: P3
X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org
X-Bugzilla-Target-Milestone: ---
X-Bugzilla-Flags:
X-Bugzilla-Changed-Fields:
Message-ID: <bug-44735-4-KgiZKMLKbN@http.gcc.gnu.org/bugzilla/>
In-Reply-To: <bug-44735-4@http.gcc.gnu.org/bugzilla/>
References: <bug-44735-4@http.gcc.gnu.org/bugzilla/>
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/
Auto-Submitted: auto-generated
MIME-Version: 1.0
X-SW-Source: 2014-08/txt/msg02050.txt.bz2
Content-length: 561
https://gcc.gnu.org/bugzilla/show_bug.cgi?idD735
--- Comment #6 from Tobias Burnus <burnus at gcc dot gnu.org> ---
Author: burnus
Date: Sat Aug 30 18:47:04 2014
New Revision: 214757
URL: https://gcc.gnu.org/viewcvs?rev!4757&root=gcc&view=rev
Log:
2014-08-30 Tobias Burnus <burnus@net-b.de>
PR fortran/62278
PR fortran/44735
PR fortran/60593
* dependency.c (gfc_check_dependency): Allow for optimizations
in the pointer-alias check.
Modified:
trunk/gcc/fortran/ChangeLog
trunk/gcc/fortran/dependency.c
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Bug c++/62314] Fix-it Hints
2014-08-30 17:19 [Bug c++/62314] New: Fix-it Hints manu at gcc dot gnu.org
2014-08-30 17:24 ` [Bug c++/62314] " manu at gcc dot gnu.org
@ 2015-09-10 20:35 ` dmalcolm at gcc dot gnu.org
1 sibling, 0 replies; 3+ messages in thread
From: dmalcolm at gcc dot gnu.org @ 2015-09-10 20:35 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62314
David Malcolm <dmalcolm at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dmalcolm at gcc dot gnu.org
--- Comment #2 from David Malcolm <dmalcolm at gcc dot gnu.org> ---
I had a go at implementing fixit-hints here:
https://gcc.gnu.org/ml/gcc-patches/2015-09/msg00732.html
and:
https://gcc.gnu.org/ml/gcc-patches/2015-09/msg00747.html
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2015-09-10 20:35 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-30 17:19 [Bug c++/62314] New: Fix-it Hints manu at gcc dot gnu.org
2014-08-30 17:24 ` [Bug c++/62314] " manu at gcc dot gnu.org
2015-09-10 20:35 ` dmalcolm at gcc dot gnu.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).