Skip to content
Snippets Groups Projects
Select Git revision
21 results Searching

Function.pmod

Blame
  • encode.c 114.09 KiB
    /*
    || This file is part of Pike. For copyright information see COPYRIGHT.
    || Pike is distributed under GPL, LGPL and MPL. See the file COPYING
    || for more information.
    || $Id: encode.c,v 1.208 2003/12/16 10:40:28 grubba Exp $
    */
    
    #include "global.h"
    #include "stralloc.h"
    #include "pike_macros.h"
    #include "object.h"
    #include "constants.h"
    #include "interpret.h"
    #include "svalue.h"
    #include "mapping.h"
    #include "array.h"
    #include "multiset.h"
    #include "language.h"
    #include "lex.h"
    #include "dynamic_buffer.h"
    #include "pike_error.h"
    #include "operators.h"
    #include "builtin_functions.h"
    #include "module_support.h"
    #include "fsort.h"
    #include "threads.h"
    #include "stuff.h"
    #include "version.h"
    #include "bignum.h"
    #include "pikecode.h"
    #include "pike_types.h"
    #include "opcodes.h"
    #include "peep.h"
    
    RCSID("$Id: encode.c,v 1.208 2003/12/16 10:40:28 grubba Exp $");
    
    /* #define ENCODE_DEBUG */
    
    /* Use the old encoding method for programs. */
    /* #define OLD_PIKE_ENCODE_PROGRAM */
    
    #ifdef ENCODE_DEBUG
    /* Pass a nonzero integer as the third arg to encode_value,
     * encode_value_canonic and decode_value to activate this debug. */
    #define EDB(N,X) do { debug_malloc_touch(data); if (data->debug>=N) {X;} } while (0)
    #ifndef PIKE_DEBUG
    #error ENCODE_DEBUG requires PIKE_DEBUG
    #endif
    #else
    #define EDB(N,X) do { debug_malloc_touch(data); } while (0)
    #endif
    
    #ifdef _AIX
    #include <net/nh.h>
    #endif
    
    #ifdef HAVE_NETINET_IN_H
    #include <netinet/in.h>
    #endif
    
    #ifdef HAVE_IEEEFP_H
    #include <ieeefp.h>
    #endif /* HAVE_IEEEFP_H */
    
    #include <math.h>
    
    #ifdef PIKE_DEBUG
    #define encode_value2 encode_value2_
    #define decode_value2 decode_value2_
    #endif