Skip to content

Commit

Permalink
Use C++17 for string_view
Browse files Browse the repository at this point in the history
  • Loading branch information
Xtansia committed Apr 23, 2024
1 parent 2d26e0e commit 220a9cf
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.5)
project(bin2s)

if (${CMAKE_CXX_COMPILER_ID} STREQUAL "GNU" OR ${CMAKE_CXX_COMPILER_ID} MATCHES "Clang")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -Wall -Wextra -Wpedantic")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++17 -Wall -Wextra -Wpedantic")
set(CMAKE_CXX_FLAGS_DEBUG "-g")
set(CMAKE_CXX_FLAGS_RELEASE "-O3 -DNDEBUG")
set(CMAKE_CXX_FLAGS_RELWITHDEBINFO "-g -O2 -DNDEBUG")
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# bin2s
Convert binary files to GCC assembly modules.

A C++11 port of devkitPro's [bin2s](https://github.com/devkitPro/general-tools/blob/master/bin2s.c).
A C++17 port of devkitPro's [bin2s](https://github.com/devkitPro/general-tools/blob/master/bin2s.c).

```
bin2s {OPTIONS} [FILES...]
Expand Down
1 change: 1 addition & 0 deletions src/bin2s.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#include <iostream>
#include <regex>
#include <string>
#include <string_view>

constexpr int32_t DEFAULT_ALIGNMENT = 4;
constexpr int32_t DEFAULT_BYTES_PER_LINE = 16;
Expand Down

0 comments on commit 220a9cf

Please sign in to comment.