Ignore:
Timestamp:
2019-05-27T12:38:26Z (5 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
0d14c25
Parents:
4d51c60
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2019-02-13 16:06:49)
git-committer:
Jiří Zárevúcky <zarevucky.jiri@…> (2019-05-27 12:38:26)
Message:

Make some libc and libposix headers usable in C++

These headers either get included from standard C++ headers,
or are standard themselves, which means any unnamespaced nonstandard
identifiers are a problem. This commit attempts to fix those
issues, and removes hacks previously used in libcpp to work around it.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/posix/include/posix/string.h

    r4d51c60 rbc56f30  
    4747
    4848#include <libc/mem.h>
    49 #ifdef _HELENOS_SOURCE
    50 #undef _HELENOS_SOURCE
     49
     50#define _REALLY_WANT_STRING_H
    5151#include <libc/string.h>
    52 #define _HELENOS_SOURCE
    53 #else
    54 #include <libc/string.h>
    55 #endif
     52
     53__C_DECLS_BEGIN;
    5654
    5755/* Copying and Concatenation */
     
    7371
    7472/* Legacy Declarations */
    75 #ifndef POSIX_STRINGS_H_
    7673extern int ffs(int i);
    7774extern int strcasecmp(const char *s1, const char *s2);
    7875extern int strncasecmp(const char *s1, const char *s2, size_t n);
    79 #endif
     76
     77__C_DECLS_END;
    8078
    8179#endif  // POSIX_STRING_H_
Note: See TracChangeset for help on using the changeset viewer.