Browse Source

fix deprecation warnings: integral promotion not done

bio2
George Githinji 5 years ago
parent
commit
8d0694f864
  1. 2
      bio/bam/read.d
  2. 2
      bio/core/utils/format.d

2
bio/bam/read.d

@ -1007,7 +1007,7 @@ private:
assert(n < 16);
// http://graphics.stanford.edu/~seander/bithacks.html#ConditionalSetOrClearBitsWithoutBranching
ushort mask = cast(ushort)(1 << n);
_flag = (_flag & ~mask) | ((-cast(int)b) & mask);
_flag = (_flag & ~cast(int)(mask)) | ((-cast(int)b) & mask);
}
// If _chunk is still a slice, not an array, duplicate it.

2
bio/core/utils/format.d

@ -58,7 +58,7 @@ private {
char* wstr=str;
static if (isSigned!T) {
ulong uvalue = (value < 0) ? -value : value;
ulong uvalue = (value < 0) ? -cast(int)(value) : value;
} else {
ulong uvalue = value;
}

Loading…
Cancel
Save