From e99492eb3cb861a70fe5b286c9f601b34c18970c Mon Sep 17 00:00:00 2001 From: Joakim Hunskaar Date: Fri, 16 Jan 2026 13:33:17 +0100 Subject: [PATCH] change to c++23 and added print in featuredemo --- configuration/.vscode/c_cpp_properties.json | 6 +++--- dependencies/meson.build | 2 +- dependencies/subprojects/animationwindow/meson.build | 2 +- dependencies/subprojects/std_lib_facilities/meson.build | 2 +- dependencies/testproject_featuredemo.cpp | 4 +++- 5 files changed, 9 insertions(+), 7 deletions(-) diff --git a/configuration/.vscode/c_cpp_properties.json b/configuration/.vscode/c_cpp_properties.json index 770cd3e..88fd84c 100644 --- a/configuration/.vscode/c_cpp_properties.json +++ b/configuration/.vscode/c_cpp_properties.json @@ -15,7 +15,7 @@ "_UNICODE" ], "cStandard": "c17", - "cppStandard": "c++20", + "cppStandard": "c++23", "compilerPath": "C:\\TDT4102-mingw64\\bin\\gcc", "compileCommands": "${workspaceFolder}/build/compile_commands.json", "intelliSenseMode": "windows-gcc-x64" @@ -32,7 +32,7 @@ "_UNICODE" ], "cStandard": "c17", - "cppStandard": "c++20", + "cppStandard": "c++23", "compileCommands": "build/compile_commands.json", "intelliSenseMode": "macos-clang-x64" }, @@ -47,7 +47,7 @@ "_UNICODE" ], "cStandard": "c17", - "cppStandard": "c++20", + "cppStandard": "c++23", "compileCommands": "build/compile_commands.json", "intelliSenseMode": "linux-gcc-x64" } diff --git a/dependencies/meson.build b/dependencies/meson.build index 17d8011..e924fed 100644 --- a/dependencies/meson.build +++ b/dependencies/meson.build @@ -1,7 +1,7 @@ project('testproject', 'cpp', version : '0.1', default_options : ['warning_level=0', - 'cpp_std=c++20', + 'cpp_std=c++23', 'c_std=c17', 'default_library=static']) diff --git a/dependencies/subprojects/animationwindow/meson.build b/dependencies/subprojects/animationwindow/meson.build index ddc7f40..f524623 100644 --- a/dependencies/subprojects/animationwindow/meson.build +++ b/dependencies/subprojects/animationwindow/meson.build @@ -1,4 +1,4 @@ -project('animationwindow', ['c', 'cpp'], version: '0.01', default_options: ['cpp_std=c++20', 'c_std=c17', 'default_library=static', 'buildtype=debugoptimized']) +project('animationwindow', ['c', 'cpp'], version: '0.01', default_options: ['cpp_std=c++23', 'c_std=c17', 'default_library=static', 'buildtype=debugoptimized']) if host_machine.system() == 'windows' sdl2_dep = subproject('sdl2_windows').get_variable('sdl2_windows_dep') diff --git a/dependencies/subprojects/std_lib_facilities/meson.build b/dependencies/subprojects/std_lib_facilities/meson.build index dfefbc9..95d68ea 100644 --- a/dependencies/subprojects/std_lib_facilities/meson.build +++ b/dependencies/subprojects/std_lib_facilities/meson.build @@ -1,4 +1,4 @@ -project('std_lib_facilities', ['c', 'cpp'], version: '0.01', default_options: ['cpp_std=c++20', 'c_std=c17', 'default_library=static', 'buildtype=debugoptimized']) +project('std_lib_facilities', ['c', 'cpp'], version: '0.01', default_options: ['cpp_std=c++23', 'c_std=c17', 'default_library=static', 'buildtype=debugoptimized']) incdir = include_directories('.') install_subdir('include', install_dir: '.') diff --git a/dependencies/testproject_featuredemo.cpp b/dependencies/testproject_featuredemo.cpp index 494610c..024af56 100644 --- a/dependencies/testproject_featuredemo.cpp +++ b/dependencies/testproject_featuredemo.cpp @@ -7,6 +7,7 @@ #include #include #include +#include #include "widgets/Button.h" #include "widgets/TextInput.h" @@ -215,6 +216,7 @@ int main(int argc, char* argv[]) { } window.next_frame(); } - + // new in c++23 + std::println("hello from println"); return 0; } \ No newline at end of file