 // expand cigar ops into temp storage
 struct cigar_op_expand : public bqsr_lambda
 {
-    cigar_op_expand(bqsr_context::view ctx,
-                    const alignment_batch_device::const_view batch)
-        : bqsr_lambda(ctx, batch)
-    { }
+    using bqsr_lambda::bqsr_lambda;
 
     CUDA_HOST_DEVICE void operator() (const uint32 op_index)
     {

    CUDA_HOST_DEVICE void operator() (const uint32 read_index)
    {
        const CRQ_index idx = batch.crq_index(read_index);

        // figure out the cigar event range for this read
        const uint32 cigar_start = ctx.cigar.cigar_offsets[idx.cigar_start];
        const uint32 cigar_end = ctx.cigar.cigar_offsets[idx.cigar_start + idx.cigar_len];

        // fetch the alignment base in reference coordinates
        const uint32 seq_id = batch.chromosome[read_index];

        const uint32 reference_alignment_start = seq_base + align_offset;

        uint16 current_bp_idx = 0;
        uint16 num_errors = 0;

        // go through the cigar events looking for the event we're interested in
        for(uint32 event = idx.cigar_start; event < idx.cigar_start + idx.cigar_len; event++)
        {
            // figure out the cigar event range for this event
            const uint32 cigar_start = ctx.cigar.cigar_offsets[event];
            const uint32 cigar_end = ctx.cigar.cigar_offsets[event+1];

            switch(batch.cigars[event].op)
            {
            case cigar_op::OP_M:

                for(uint32 i = cigar_start; i < cigar_end; i++)
                {
                    // update the current read bp index
                    current_bp_idx = ctx.cigar.cigar_event_read_coordinates[i];
