"Fossies" - the Fresh Open Source Software Archive

Member "uriparser-0.9.5/include/uriparser/UriDefsUnicode.h" (18 Mar 2021, 2600 Bytes) of package /linux/www/uriparser-0.9.5.tar.xz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "UriDefsUnicode.h" see the Fossies "Dox" file reference documentation and the latest Fossies "Diffs" side-by-side code changes report: 0.9.4_vs_0.9.5.

    1 /*
    2  * uriparser - RFC 3986 URI parsing library
    3  *
    4  * Copyright (C) 2007, Weijia Song <songweijia@gmail.com>
    5  * Copyright (C) 2007, Sebastian Pipping <sebastian@pipping.org>
    6  * All rights reserved.
    7  *
    8  * Redistribution and use in source  and binary forms, with or without
    9  * modification, are permitted provided  that the following conditions
   10  * are met:
   11  *
   12  *     1. Redistributions  of  source  code   must  retain  the  above
   13  *        copyright notice, this list  of conditions and the following
   14  *        disclaimer.
   15  *
   16  *     2. Redistributions  in binary  form  must  reproduce the  above
   17  *        copyright notice, this list  of conditions and the following
   18  *        disclaimer  in  the  documentation  and/or  other  materials
   19  *        provided with the distribution.
   20  *
   21  *     3. Neither the  name of the  copyright holder nor the  names of
   22  *        its contributors may be used  to endorse or promote products
   23  *        derived from  this software  without specific  prior written
   24  *        permission.
   25  *
   26  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
   27  * "AS IS" AND  ANY EXPRESS OR IMPLIED WARRANTIES,  INCLUDING, BUT NOT
   28  * LIMITED TO,  THE IMPLIED WARRANTIES OF  MERCHANTABILITY AND FITNESS
   29  * FOR  A  PARTICULAR  PURPOSE  ARE  DISCLAIMED.  IN  NO  EVENT  SHALL
   30  * THE  COPYRIGHT HOLDER  OR CONTRIBUTORS  BE LIABLE  FOR ANY  DIRECT,
   31  * INDIRECT, INCIDENTAL, SPECIAL,  EXEMPLARY, OR CONSEQUENTIAL DAMAGES
   32  * (INCLUDING, BUT NOT LIMITED TO,  PROCUREMENT OF SUBSTITUTE GOODS OR
   33  * SERVICES; LOSS OF USE, DATA,  OR PROFITS; OR BUSINESS INTERRUPTION)
   34  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
   35  * STRICT  LIABILITY,  OR  TORT (INCLUDING  NEGLIGENCE  OR  OTHERWISE)
   36  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
   37  * OF THE POSSIBILITY OF SUCH DAMAGE.
   38  */
   39 
   40 /**
   41  * @file UriDefsUnicode.h
   42  * Holds definitions for the wide string pass.
   43  * NOTE: This header is included N times, not once.
   44  */
   45 
   46 /* Allow multi inclusion */
   47 #include "UriDefsConfig.h"
   48 
   49 
   50 
   51 #undef URI_CHAR
   52 #define URI_CHAR wchar_t
   53 
   54 #undef _UT
   55 #define _UT(x) L##x
   56 
   57 
   58 
   59 #undef URI_FUNC
   60 #define URI_FUNC(x) uri##x##W
   61 
   62 #undef URI_TYPE
   63 #define URI_TYPE(x) Uri##x##W
   64 
   65 
   66 
   67 #undef URI_STRLEN
   68 #define URI_STRLEN wcslen
   69 #undef URI_STRCPY
   70 #define URI_STRCPY wcscpy
   71 #undef URI_STRCMP
   72 #define URI_STRCMP wcscmp
   73 #undef URI_STRNCMP
   74 #define URI_STRNCMP wcsncmp
   75 
   76 /* TODO Remove on next source-compatibility break */
   77 #undef URI_SNPRINTF
   78 #if (defined(__WIN32__) || defined(_WIN32) || defined(WIN32))
   79 # define URI_SNPRINTF _snwprintf
   80 #else
   81 # define URI_SNPRINTF swprintf
   82 #endif