mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-04 18:29:37 +02:00
GP-0 Added assertion check for datatype replacement
This commit is contained in:
parent
4f95fdd111
commit
d3fbdbe0a3
1 changed files with 5 additions and 0 deletions
|
@ -2431,6 +2431,11 @@ abstract public class DataTypeManagerDB implements DataTypeManager {
|
|||
* @param replacementDataType datatype which is the replacement
|
||||
*/
|
||||
protected void addDataTypeToReplace(DataType oldDataType, DataType replacementDataType) {
|
||||
Objects.requireNonNull(oldDataType);
|
||||
Objects.requireNonNull(replacementDataType);
|
||||
if (oldDataType == replacementDataType) {
|
||||
throw new AssertionError("Invalid datatype replacement pair");
|
||||
}
|
||||
typesToReplace.add(new Pair<>(oldDataType, replacementDataType));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue