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

check50 ANSI and HTML output do not make clear when stdout has unprintable characters #287

Open
dmalan opened this issue Sep 14, 2022 · 1 comment

Comments

@dmalan
Copy link
Member

dmalan commented Sep 14, 2022

As in a bug like

#include <stdio.h>

int foo(char c)
{
    printf('%c', c + 1);
    return 0;
}

int main(void)
{
    char c = 'a';
    printf('%c', foo(c));
}

which ends up printing b followed by an invisible NUL (because mainprintsfoo's return value) followed by \n, which wouldn't match an expectation of b\n, but whose NUL student could not see in check50`'s output.

@goyalyashpal
Copy link

- which ends up printing `b` followed by an invisible NUL (because main`prints`foo`'s return value) followed by `\n`, which wouldn't match an expectation of `b\n`, but whose NUL student could not see in `check50`'s output.
+ which ends up printing `b` followed by an invisible NUL (because ``main`prints`foo``'s return value) followed by `\n`, which wouldn't match an expectation of `b\n`, but whose NUL student could not see in `check50`'s output.

Original in description:

which ends up printing b followed by an invisible NUL (because mainprintsfoo's return value) followed by \n, which wouldn't match an expectation of b\n, but whose NUL student could not see in check50`'s output.

I think what was intended:

which ends up printing b followed by an invisible NUL (because main`prints`foo's return value) followed by \n, which wouldn't match an expectation of b\n, but whose NUL student could not see in check50's output.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants