mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
Bugzilla 251039.
This commit is contained in:
parent
3fd4ddeddc
commit
0113d94674
3 changed files with 18 additions and 0 deletions
|
@ -655,6 +655,9 @@ public class RegisterBitFieldVMNode extends AbstractExpressionVMNode
|
|||
*/
|
||||
int startIdx = "GRP(".length(); //$NON-NLS-1$
|
||||
int endIdx = expression.indexOf(')', startIdx);
|
||||
if ( startIdx == -1 || endIdx == -1 ) {
|
||||
return null;
|
||||
}
|
||||
String remaining = expression.substring(endIdx+1);
|
||||
if ( ! remaining.startsWith(".REG(") ) { //$NON-NLS-1$
|
||||
return null;
|
||||
|
@ -665,6 +668,9 @@ public class RegisterBitFieldVMNode extends AbstractExpressionVMNode
|
|||
*/
|
||||
startIdx = ".REG(".length(); //$NON-NLS-1$
|
||||
endIdx = remaining.indexOf(')', startIdx);
|
||||
if ( startIdx == -1 || endIdx == -1 ) {
|
||||
return null;
|
||||
}
|
||||
remaining = remaining.substring(endIdx+1);
|
||||
|
||||
/*
|
||||
|
@ -675,6 +681,9 @@ public class RegisterBitFieldVMNode extends AbstractExpressionVMNode
|
|||
}
|
||||
startIdx = ".BFLD(".length(); //$NON-NLS-1$
|
||||
endIdx = remaining.indexOf(')', startIdx);
|
||||
if ( startIdx == -1 || endIdx == -1 ) {
|
||||
return null;
|
||||
}
|
||||
String bitFieldName = remaining.substring(startIdx, endIdx);
|
||||
|
||||
/*
|
||||
|
|
|
@ -359,6 +359,9 @@ public class RegisterGroupVMNode extends AbstractExpressionVMNode
|
|||
*/
|
||||
int startIdx = "GRP(".length(); //$NON-NLS-1$
|
||||
int endIdx = expression.indexOf(')', startIdx);
|
||||
if ( startIdx == -1 || endIdx == -1 ) {
|
||||
return null;
|
||||
}
|
||||
String groupName = expression.substring(startIdx, endIdx);
|
||||
return groupName.trim();
|
||||
}
|
||||
|
|
|
@ -648,6 +648,9 @@ public class RegisterVMNode extends AbstractExpressionVMNode
|
|||
*/
|
||||
int startIdx = "GRP(".length(); //$NON-NLS-1$
|
||||
int endIdx = expression.indexOf(')', startIdx);
|
||||
if ( startIdx == -1 || endIdx == -1 ) {
|
||||
return null;
|
||||
}
|
||||
String remaining = expression.substring(endIdx+1);
|
||||
if ( ! remaining.startsWith(".REG(") ) { //$NON-NLS-1$
|
||||
return null;
|
||||
|
@ -658,6 +661,9 @@ public class RegisterVMNode extends AbstractExpressionVMNode
|
|||
*/
|
||||
startIdx = ".REG(".length(); //$NON-NLS-1$
|
||||
endIdx = remaining.indexOf(')', startIdx);
|
||||
if ( startIdx == -1 || endIdx == -1 ) {
|
||||
return null;
|
||||
}
|
||||
String regName = remaining.substring(startIdx,endIdx);
|
||||
return regName.trim();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue