From e3d7dfb83b06239c10e3e5b0f5dcd9e3b93925e8 Mon Sep 17 00:00:00 2001 From: DrNuget Date: Sun, 2 Nov 2025 01:51:45 +0200 Subject: turn code back to c99 compliant, change c standard back to c99 --- Makefile | 2 +- brailleboi.c | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index d52f23b..8983dce 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ CC = gcc -CFLAGS = -std=c23 -Wpedantic +CFLAGS = -std=c99 -Wpedantic SRC = main.c brailleboi.c brailleboi.h diff --git a/brailleboi.c b/brailleboi.c index d28a7d1..7957d8b 100644 --- a/brailleboi.c +++ b/brailleboi.c @@ -25,9 +25,9 @@ int brailleStop(image_buffer* buf) int brailleReorganizeBits(int old) { //Reorganizes bits because the unicode standard for 8 dotted braille is weird - int new = (old&0b10000111) | - (old&0b01110000)>>1 | - (old&0b00001000)<<3; + int new = (old&0x87) | // 0b10000111 + (old&0x70)>>1 | // 0b01110000 + (old&0x08)<<3; // 0b00001000 return new; } -- cgit v1.2.3