* Set a specific array element's null-bitmap entry * * nullbitmap: pointer to array's null bitmap (mustn't be NULL) * offset: 0-based linear element number of array element * isNull: null status to set */
| 4685 | * isNull: null status to set |
| 4686 | */ |
| 4687 | static void |
| 4688 | array_set_isnull(bits8 *nullbitmap, int offset, bool isNull) |
| 4689 | { |
| 4690 | int bitmask; |
| 4691 | |
| 4692 | nullbitmap += offset / 8; |
| 4693 | bitmask = 1 << (offset % 8); |
| 4694 | if (isNull) |
| 4695 | *nullbitmap &= ~bitmask; |
| 4696 | else |
| 4697 | *nullbitmap |= bitmask; |
| 4698 | } |
| 4699 | |
| 4700 | /* |
| 4701 | * Fetch array element at pointer, converted correctly to a Datum |