Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing output of strings with non printable characters #65

Merged
merged 29 commits into from
Dec 17, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
8239a77
Bump workflows with deprecation warning
JBenda Dec 6, 2023
9c862cc
Add new test based on https://github.com/brwarner/inkcpp/issues/63
JBenda Dec 12, 2023
e5d1c97
Add check if end after begin for removing spaces
JBenda Dec 13, 2023
810261d
Clear data from managed_array on decstruction
JBenda Dec 13, 2023
52cf7b9
Bump inkproof to master
JBenda Dec 13, 2023
4c99776
Fix pull request report condition
JBenda Dec 13, 2023
d1dbb2e
Debug output for badge
JBenda Dec 13, 2023
57476a8
Add permissions
JBenda Dec 13, 2023
2594041
fix typo
JBenda Dec 13, 2023
7b99da2
extend tag label
JBenda Dec 13, 2023
030c5a7
Disable fall through shortcut in jump()
JBenda Dec 14, 2023
e2c28f0
Update Readme references
JBenda Dec 14, 2023
69765f1
add clang format
JBenda Dec 15, 2023
b3cf913
Formatting
JBenda Dec 15, 2023
a4a8688
more formatting
JBenda Dec 15, 2023
d296516
Change ref in format command
JBenda Dec 15, 2023
01ea015
Install clang 16 on Ubuntu LTS 22.04
JBenda Dec 15, 2023
9c3dd88
add sudo rigths
JBenda Dec 15, 2023
79df928
remove specifit identifier
JBenda Dec 15, 2023
f02ac0c
update condition with -q
JBenda Dec 15, 2023
fba989f
install all llvm
JBenda Dec 15, 2023
4013484
us format 15
JBenda Dec 15, 2023
f8da66e
Fix format config for older version
JBenda Dec 15, 2023
4eeaadc
Installed version 15 explicit
JBenda Dec 15, 2023
13dfe68
downgrade again
JBenda Dec 15, 2023
e6ba67e
format with new rules
JBenda Dec 15, 2023
b211f20
new break
JBenda Dec 15, 2023
a307589
formatting
JBenda Dec 15, 2023
eceb5f8
formatting bug
JBenda Dec 15, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add check if end after begin for removing spaces
  • Loading branch information
JBenda committed Dec 13, 2023
commit e5d1c973051ae240dc82bb568e3501736885b196
8 changes: 6 additions & 2 deletions inkcpp/output.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,12 @@ namespace ink::runtime::internal
std::string result = str.str();
if ( !result.empty() ) {
auto end = clean_string<true, false>( result.begin(), result.end() );
_last_char = *( end - 1 );
result.resize( end - result.begin() - ( _last_char == ' ' ? 1 : 0 ) );
if (result.begin() == end) {
result.resize(0);
} else {
_last_char = *( end - 1 );
result.resize( end - result.begin() - ( _last_char == ' ' ? 1 : 0 ) );
}
}
return result;
}
Expand Down
2 changes: 1 addition & 1 deletion inkcpp/runner_impl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ namespace ink::runtime::internal

const uint32_t* iter = nullptr;
container_t id;
ip_t offset;
ip_t offset = nullptr;
size_t comm_end;
bool reversed = _ptr > dest;

Expand Down