コード例 #1
0
        /// <summary>
        /// Reads a raw <c>CustomDebugInformation</c> row or returns false if the row doesn't exist
        /// </summary>
        /// <param name="rid">Row ID</param>
        /// <param name="row">Row data</param>
        /// <returns></returns>
        public bool TryReadCustomDebugInformationRow(uint rid, out RawCustomDebugInformationRow row)
        {
            var table = CustomDebugInformationTable;

            if (table.IsInvalidRID(rid))
            {
                row = default;
                return(false);
            }
            var reader = table.DataReader;

            reader.Position = (rid - 1) * (uint)table.TableInfo.RowSize;
            row             = new RawCustomDebugInformationRow(
                table.Column0.Unsafe_Read24(ref reader),
                table.Column1.Unsafe_Read24(ref reader),
                table.Column2.Unsafe_Read24(ref reader));
            return(true);
        }
コード例 #2
0
 public int GetHashCode(RawCustomDebugInformationRow obj) =>
 (int)obj.Parent +
 rol(obj.Kind, 3) +
 rol(obj.Value, 7);
コード例 #3
0
 public bool Equals(RawCustomDebugInformationRow x, RawCustomDebugInformationRow y) =>
 x.Parent == y.Parent &&
 x.Kind == y.Kind &&
 x.Value == y.Value;
コード例 #4
0
ファイル: RawRowColumnReader.cs プロジェクト: zz110/dnSpy
 static uint ReadCustomDebugInformationColumnMethod(ref RawCustomDebugInformationRow row, int index) => row[index];