Home
       strxfrm.3 - scc - simple c99 compiler
  HTML git clone git://git.simple-cc.org/scc
   DIR Log
   DIR Files
   DIR Refs
   DIR Submodules
   DIR README
   DIR LICENSE
       ---
       strxfrm.3 (1132B)
       ---
            1 .TH strxfrm 3
            2 .SH NAME
            3 strxfrm - string transformation
            4 .SH SYNOPSIS
            5 #include <string.h>
            6 
            7 size_t strxfrm(char *restrict s1, const char *restrict s2, size_t n)
            8 .SH DESCRIPTION
            9 The
           10 .BR strxfrm ()
           11 function transforms
           12 the string pointed to by
           13 .I s2
           14 and places the resulting string
           15 into the array pointed to by
           16 .IR s1 .
           17 The transformation is such that
           18 if the strcmp function is applied to two transformed strings,
           19 it returns a value
           20 greater than, equal to or less than zero,
           21 corresponding to the result of the strcoll function
           22 applied to the same two original strings.
           23 .PP
           24 No more than n characters shall be placed into
           25 the resulting array pointed to by
           26 .IR s1 ,
           27 including the terminating null character.
           28 If n is zero,
           29 .I s1
           30 is permitted to be a null pointer.
           31 .PP
           32 If copying takes place between objects that overlap,
           33 the behaviour is undefined.
           34 .SH RETURN VALUE
           35 The
           36 .BR strxfrm ()
           37 function shall return the length of
           38 the transformed string
           39 (not including the terminating null character).
           40 If the value returned is
           41 .I n
           42 or more,
           43 the contents of the array pointed to
           44 .I s1
           45 are indeterminate.
           46 .SH STANDARDS
           47 ISO/IEC 9899:1999 Section 7.21.4.5