On 2017/10/9 22:16, David Malcolm wrote:
I have some concerns about adding non-trivial host-specific code to the
diagnostics subsystem.

I occasionally make changes to the files you're touching, but I don't
have access to the host in question, so I can't test that I don't break
things on MinGW.

Is it OK if this is the MinGW team's problem, and not mine?  (i.e. can
you please clean up after me if I break something on MinGW?).

I am tracing the branch for the latest stable major release (`gcc-7-branch` at the moment) closely. If anything is broken I will let you know.

Also, you might want to add some selftests to the code e.g. for
find_esc_head and find_esc_terminator.
Those functions are static - they will not be visible elsewhere. They are formulated for clarification purposes and nothing else.

I looked at the docs for the
Windows console API and unfortunately there doesn't seem to be a way to
set up a dummy console for unit-testing the parts of the code that call
the console API directly.  But find_esc_head and find_esc_terminator
don't directly call the API, and hence you can write some selftest
functions for them.  (there's probably a much more involved way to test
this using mocks/stubs for the console API, but that's probably
overkill).

Dave




--
Best regards,
LH_Mouse

Reply via email to