memoryFootprint should return size_t not optional<size_t>