BaseTools/VfrCompile: Add assignment operator definition for some classes
For class that defines the copy constructor, it is better to add the assignment operator definition as well. This commit adds the definition for assignment operator for the classes with the copy constructor defined. Cc: Liming Gao <liming.gao@intel.com> Cc: Yonghong Zhu <yonghong.zhu@intel.com> Cc: Eric Dong <eric.dong@intel.com> Cc: Dandan Bi <dandan.bi@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
This commit is contained in:
@ -2390,6 +2390,22 @@ EFI_VARSTORE_INFO::EFI_VARSTORE_INFO (
|
||||
mVarTotalSize = Info.mVarTotalSize;
|
||||
}
|
||||
|
||||
EFI_VARSTORE_INFO&
|
||||
EFI_VARSTORE_INFO::operator= (
|
||||
IN CONST EFI_VARSTORE_INFO &Info
|
||||
)
|
||||
{
|
||||
if (this != &Info) {
|
||||
mVarStoreId = Info.mVarStoreId;
|
||||
mInfo.mVarName = Info.mInfo.mVarName;
|
||||
mInfo.mVarOffset = Info.mInfo.mVarOffset;
|
||||
mVarType = Info.mVarType;
|
||||
mVarTotalSize = Info.mVarTotalSize;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
BOOLEAN
|
||||
EFI_VARSTORE_INFO::operator == (
|
||||
IN EFI_VARSTORE_INFO *Info
|
||||
|
Reference in New Issue
Block a user