Changes the value of the minimum heap element and rebalances the heap.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(dbcsr_heap_type), | intent(inout) | :: | heap | |||
integer(kind=valt), | intent(in) | :: | value |
SUBROUTINE dbcsr_heap_reset_first(heap, value) !! Changes the value of the minimum heap element and rebalances the heap. TYPE(dbcsr_heap_type), INTENT(INOUT) :: heap INTEGER(KIND=valt), INTENT(IN) :: value DBCSR_ASSERT(heap%n > 0) heap%nodes(1)%node%value = value CALL bubble_down(heap, 1) END SUBROUTINE dbcsr_heap_reset_first