Skip to content

Backspace (\b) and Carriage Return (\r) not working as expected in C++ output #691

Open
@TWJackXD

Description

@TWJackXD

Hello,

I encountered an issue while using the Piston API with C++. When I run the following code:

#include <iostream>
using namespace std;

int main() {
    cout << "ABCD\b\b1234" << endl;
    return 0;
}

In other compilers, the output I get is:

AB1234

However, when I try the same code using the Piston API, it does not produce the expected result.

Expected Output:

AB1234

Actual Output:

ABCD1234

The backspace (\b) escape sequence does not seem to function as expected, and the carriage return (\r) appears to have similar behavior.

I would appreciate it if you could look into this issue or provide guidance on how to handle escape sequences like \b and \r with the Piston API. Thank you for your time and assistance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions