Thomas,
On Tue, Sep 30, 2014 at 11:06 AM, Thomas Preud'homme
<[email protected]> wrote:
strpbrk (file_name,"\*?")
ir order to know if i have a simple file name, tcc tells me "unknown
escape sequence".
The manpage doesn't say that the strings accept escape sequence. Is
it even
defined in the standard? Sounds like a bug in TinyCC.
I believe the compiler is supposed to perform all C escapes on quoted
strings during compile time, converting them to the proper sequences
before passing it to strpbrk.
However, strpbrk doesn't accept a regex or shell globs. I don't see
why you would be checking for '*' or '?' in a filename!
If TCC says \* is an unknown escape sequence then that looks like
exactly what it should be doing. There is no such escape.
Try basename() instead.
As for text[i]='\\', I'm betting when he says "do not work" its a
run-time error due to a bug in his code, not a TCC bug.
_______________________________________________
Tinycc-devel mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/tinycc-devel