mirror of
				https://github.com/Z3Prover/z3
				synced 2025-11-04 13:29:11 +00:00 
			
		
		
		
	fix #7196: make the code C++23 compatible
Nikolaj is now more bleeding edge than I am... I must be getting old? (˘・_・˘)
This commit is contained in:
		
							parent
							
								
									84092cbd96
								
							
						
					
					
						commit
						918ac2b176
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -21,7 +21,7 @@ Revision History:
 | 
			
		|||
--*/
 | 
			
		||||
#pragma once
 | 
			
		||||
 | 
			
		||||
#include <type_traits>
 | 
			
		||||
#include <cstddef>
 | 
			
		||||
#include "util/memory_manager.h"
 | 
			
		||||
 | 
			
		||||
template<typename T, bool CallDestructors=true, unsigned INITIAL_SIZE=16>
 | 
			
		||||
| 
						 | 
				
			
			@ -30,7 +30,7 @@ protected:
 | 
			
		|||
    T *      m_buffer = reinterpret_cast<T*>(m_initial_buffer);
 | 
			
		||||
    unsigned m_pos = 0;
 | 
			
		||||
    unsigned m_capacity = INITIAL_SIZE;
 | 
			
		||||
    typename std::aligned_storage<sizeof(T), alignof(T)>::type m_initial_buffer[INITIAL_SIZE];
 | 
			
		||||
    alignas(T) std::byte m_initial_buffer[INITIAL_SIZE * sizeof(T)];
 | 
			
		||||
 | 
			
		||||
    void free_memory() {
 | 
			
		||||
        if (m_buffer != reinterpret_cast<T*>(m_initial_buffer)) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue