MiKTeX 26.5-next
A scalable TeX distribution
Loading...
Searching...
No Matches
Emulation.h File Reference

Utilities for emulating Web2c. More...

#include <miktex/Definitions>
#include <miktex/Core/Debug>
#include <miktex/Core/IntegerTypes>
#include <miktex/Version>
#include <miktex/KPSE/Emulation>
#include "pre.h"
#include "../../c-auto.h"
#include "../../w2c/config.h"
#include "../../lib/lib.h"
Include dependency graph for Emulation.h:

Go to the source code of this file.

Namespaces

namespace  MiKTeX::Web2C
 MiKTeX Web2C emulation utilities.

Functions

char * MiKTeX::Web2C::GetCurrentFileName ()
void MiKTeX::Web2C::GetSecondsAndMicros (int *seconds, int *micros)
int MiKTeX::Web2C::RunSystemCommand (const char *cmd)
integer miktex_zround (double r)
texmfmp.h

Stuff from texmfmp.h.

char * generic_synctex_get_current_name ()
int runsystem (const char *cmd)
void secondsandmicros (integer &s, integer &m)

cpascal.h

Stuff from cpascal.h.

#define decr(x)
#define incr(x)
#define halfp(i)
#define ISDIRSEP   IS_DIR_SEP
#define libcfree   free
#define odd(x)
#define round(x)
#define xmallocarray(type, size)
#define xreallocarray(ptr, type, size)
#define nil   nullptr
#define kpsevarvalue   kpse_var_value
#define kpseinitprog   kpse_init_prog
#define kpsesetprogramenabled   kpse_set_program_enabled
#define kpsepkformat   kpse_pk_format
#define kpsesrccmdline   kpse_src_cmdline
#define kpsemaketexdiscarderrors   kpse_make_tex_discard_errors
#define intcast(x)
#define stringcast(x)
#define ucharcast(x)
#define ustringcast(x)
#define promptfilenamehelpmsg   "(Press Enter to retry, or Control-Z to exit"
#define vgetc(f)
#define cinttype   int
typedef double real
template<class T>
T * addressof (T &x)
template<class T>
const char * conststringcast (T *s)

Detailed Description

Utilities for emulating Web2c.

Author
Christian Schenk

In order to support programs relying on Web2c, we implement an emulation library.

This file is part of the MiKTeX W2CEMU Library.

MiKTeX W2CEMU Library is licensed under GNU General Public License version 2 or any later version.

Macro Definition Documentation

◆ decr

#define decr ( x)
Value:
--(x)

◆ halfp

#define halfp ( i)
Value:
((i) >> 1)

◆ incr

#define incr ( x)
Value:
++(x)

◆ intcast

#define intcast ( x)
Value:
((integer)(x))

◆ odd

#define odd ( x)
Value:
((x) & 1)

◆ round

#define round ( x)
Value:
miktex_zround((double) (x))

◆ stringcast

#define stringcast ( x)
Value:
((char *) (x))

◆ ucharcast

#define ucharcast ( x)
Value:
((unsigned char)(x))

◆ ustringcast

#define ustringcast ( x)
Value:
((unsigned char *) (x))

◆ vgetc

#define vgetc ( f)
Value:
(void)getc(f)

◆ xmallocarray

#define xmallocarray ( type,
size )
Value:
((type*)xmalloc(((size) + 1) * sizeof(type)))

◆ xreallocarray

#define xreallocarray ( ptr,
type,
size )
Value:
((type*)xrealloc(ptr, ((size) + 1) * sizeof(type)))