Ghidra is a software reverse engineering (SRE) framework
Copy constructor on LaneDescription
caheckman5ef7347ca3ce
diff --git a/Ghidra/Features/Decompiler/src/decompile/cpp/transform.cc b/Ghidra/Features/Decompiler/src/decompile/cpp/transform.ccindex f2139d79e3..d8fe8a05d9 100644--- a/Ghidra/Features/Decompiler/src/decompile/cpp/transform.cc+++ b/Ghidra/Features/Decompiler/src/decompile/cpp/transform.cc@@ -16,6 +16,15 @@#include "transform.hh"#include "funcdata.hh"+/// \param op2 is the lane description to copy from+LaneDescription::LaneDescription(const LaneDescription &op2)++{+ wholeSize = op2.wholeSize;+ laneSize = op2.laneSize;+ lanePosition = op2.lanePosition;+}+/// Create lanes that are all the same size/// \param origSize is the size of the whole in bytes/// \param sz is the size of a lane in bytesdiff --git a/Ghidra/Features/Decompiler/src/decompile/cpp/transform.hh b/Ghidra/Features/Decompiler/src/decompile/cpp/transform.hhindex a388b3d811..9c5f106356 100644--- a/Ghidra/Features/Decompiler/src/decompile/cpp/transform.hh+++ b/Ghidra/Features/Decompiler/src/decompile/cpp/transform.hh@@ -94,6 +94,7 @@ class LaneDescription {vector<int4> laneSize; ///< Size of lanes in bytesvector<int4> lanePosition; ///< Significance positions of lanes in bytespublic:+ LaneDescription(const LaneDescription &op2); ///< Copy constructorLaneDescription(int4 origSize,int4 sz); ///< Construct uniform lanesLaneDescription(int4 origSize,int4 lo,int4 hi); ///< Construct two lanes of arbitrary sizeint4 getNumLanes(void) const { return laneSize.size(); } ///< Get the total number of lanes