1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-08-14 03:35:37 +02:00

Fix for PR 46592: Debug View shows Functions as func(type param,...)().

In some situations gdb returns the function names that include parameter types. 
To make the presentation consistent truncate the parameters.
This commit is contained in:
Mikhail Khodjaiants 2003-11-13 21:18:32 +00:00
parent 74005e4343
commit 104831688d
2 changed files with 20 additions and 1 deletions

View file

@ -1,3 +1,10 @@
2003-11-13 Mikhail Khodjaiants
* src/org/eclipse/cdt/debug/mi/core/output/MIFrame.java
Fix for PR 46592: Debug View shows Functions as func(type param,...)().
In some situations gdb returns the function names that include parameter types.
To make the presentation consistent truncate the parameters.
2003-11-06 Alain Magloire
* src/org/eclipse/cdt/debug/mi/core/cdi/EventManager.java:

View file

@ -84,7 +84,19 @@ public class MIFrame {
} catch (NumberFormatException e) {
}
} else if (var.equals("func")) {
func = ( str != null && str.equals( "??" ) ) ? "" : str;
func = null;
if ( str != null ) {
str = str.trim();
if ( str.equals( "??" ) )
func = "";
// In some situations gdb returns the function names that include parameter types.
// To make the presentation consistent truncate the parameters. PR 46592
int end = str.indexOf( '(' );
if ( end != -1 )
func = str.substring( 0, end );
else
func = str;
}
} else if (var.equals("file")) {
file = str;
} else if (var.equals("line")) {