I am creating a main function to test the limits of a C function called mchar. mchar takes a char as an argument.
int main ()
{
mchar();
mchar('A');
mchar('\n');
mchar('');
mchar(NULL);
}
I am trying to think of all possible use cases that could possible call the method to go wrong. Will all of these be able to be called properly? And are there any use cases that I am missing?
There are only 256 characters so you can easily call it with all of them:
If you specifically want to test “interesting” characters, then you might try these ones.