[#BloombergLP-bdlb-BitStringUtil-remove]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlb.adoc[bdlb]::xref:BloombergLP/bdlb/BitStringUtil.adoc[BitStringUtil]::remove
:relfileprefix: ../../../
:mrdocs:

Remove bits from a bit string, shifting higher bits down&period;

== Synopsis

Declared in `&lt;bdlb&lowbar;bitstringutil&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
void
remove(
    uint64&lowbar;t* bitString,
    std::size&lowbar;t length,
    std::size&lowbar;t index,
    std::size&lowbar;t numBits);
----

== Description

Remove the specified `numBits` from the specified `bitString` of the specified `length` beginning at the specified `index`&period; Bits above `index &plus; numBits` are shifted down by `numBits` index positions and the length of `bitString` is reduced by `numBits`&period; The values of the vacated high&hyphen;order bits are not modified&period; The behavior is undefined unless `index &plus; numBits &lt;&equals; length`&period;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *bitString*
| bit string to modify
| *length*
| number of bits in `bitString`
| *index*
| starting bit position of the range to remove
| *numBits*
| number of bits to remove
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
