Amandeep Grewal
Amandeep Grewal

Reputation: 1821

Is strtok in C89?

Is the strtok function in standard C89?

Upvotes: 3

Views: 685

Answers (2)

Jens
Jens

Reputation: 72707

There are lists enumerating functions and other identifiers by standard and header. See e.g. http://www.schweikhardt.net/identifiers.html

Upvotes: 1

John Ledbetter
John Ledbetter

Reputation: 14203

the man page says:

CONFORMING TO
       strtok()
              SVr4, POSIX.1-2001, 4.3BSD, C89, C99.

       strtok_r()
              POSIX.1-2001.

So I would say yes.

According to the C89 draft I have (the actual standard costs money), the appropriate section is:

4.11 STRING HANDLING <string.h>

     4.11.5.8 The strtok function

Upvotes: 15

Related Questions