Add compiler_support.h (#25274)
				
					
				
			This commit is contained in:
		
							parent
							
								
									fa24b0fcce
								
							
						
					
					
						commit
						955809bd5a
					
				
					 36 changed files with 142 additions and 81 deletions
				
			
		| 
						 | 
				
			
			@ -19,6 +19,7 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
 | 
			
		|||
 | 
			
		||||
#include <string.h>
 | 
			
		||||
 | 
			
		||||
#include "compiler_support.h"
 | 
			
		||||
#include "keyboard.h"
 | 
			
		||||
#include "progmem.h"
 | 
			
		||||
#include "timer.h"
 | 
			
		||||
| 
						 | 
				
			
			@ -265,7 +266,7 @@ void st7565_write_char(const char data, bool invert) {
 | 
			
		|||
    static uint8_t st7565_temp_buffer[ST7565_FONT_WIDTH];
 | 
			
		||||
    memcpy(&st7565_temp_buffer, st7565_cursor, ST7565_FONT_WIDTH);
 | 
			
		||||
 | 
			
		||||
    _Static_assert(sizeof(font) >= ((ST7565_FONT_END + 1 - ST7565_FONT_START) * ST7565_FONT_WIDTH), "ST7565_FONT_END references outside array");
 | 
			
		||||
    STATIC_ASSERT(sizeof(font) >= ((ST7565_FONT_END + 1 - ST7565_FONT_START) * ST7565_FONT_WIDTH), "ST7565_FONT_END references outside array");
 | 
			
		||||
 | 
			
		||||
    // set the reder buffer data
 | 
			
		||||
    uint8_t cast_data = (uint8_t)data; // font based on unsigned type for index
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue