mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2025-02-20 18:32:01 +00:00
Moving prog_section and prog_header to gmqcc.h to not have it twice: previously was in code.c and exec.h
This commit is contained in:
parent
178dcb13aa
commit
f1a2ac624f
3 changed files with 19 additions and 38 deletions
19
code.c
19
code.c
|
@ -22,25 +22,6 @@
|
|||
*/
|
||||
#include "gmqcc.h"
|
||||
|
||||
typedef struct {
|
||||
uint32_t offset; /* Offset in file of where data begins */
|
||||
uint32_t length; /* Length of section (how many of) */
|
||||
} prog_section;
|
||||
|
||||
typedef struct {
|
||||
uint32_t version; /* Program version (6) */
|
||||
uint16_t crc16; /* What is this? */
|
||||
uint16_t skip; /* see propsal.txt */
|
||||
|
||||
prog_section statements; /* prog_section_statement */
|
||||
prog_section defs; /* prog_section_def */
|
||||
prog_section fields; /* prog_section_field */
|
||||
prog_section functions; /* prog_section_function */
|
||||
prog_section strings; /* What is this? */
|
||||
prog_section globals; /* What is this? */
|
||||
uint32_t entfield; /* Number of entity fields */
|
||||
} prog_header;
|
||||
|
||||
/*
|
||||
* The macros below expand to a typesafe vector implementation, which
|
||||
* can be viewed in gmqcc.h
|
||||
|
|
19
exec.h
19
exec.h
|
@ -45,25 +45,6 @@ typedef union {
|
|||
typedef char qcfloat_size_is_correct [sizeof(qcfloat) == 4 ?1:-1];
|
||||
typedef char qcint_size_is_correct [sizeof(qcint) == 4 ?1:-1];
|
||||
|
||||
typedef struct {
|
||||
uint32_t offset;
|
||||
uint32_t length;
|
||||
} prog_section;
|
||||
|
||||
typedef struct {
|
||||
uint32_t version;
|
||||
uint16_t crc16;
|
||||
uint16_t skip;
|
||||
|
||||
prog_section statements;
|
||||
prog_section defs;
|
||||
prog_section fields;
|
||||
prog_section functions;
|
||||
prog_section strings;
|
||||
prog_section globals;
|
||||
uint32_t entfield;
|
||||
} prog_header;
|
||||
|
||||
typedef prog_section_both prog_def;
|
||||
typedef prog_section_function prog_function;
|
||||
typedef prog_section_statement prog_statement;
|
||||
|
|
19
gmqcc.h
19
gmqcc.h
|
@ -372,6 +372,25 @@ enum {
|
|||
|
||||
extern size_t type_sizeof[TYPE_COUNT];
|
||||
|
||||
typedef struct {
|
||||
uint32_t offset; /* Offset in file of where data begins */
|
||||
uint32_t length; /* Length of section (how many of) */
|
||||
} prog_section;
|
||||
|
||||
typedef struct {
|
||||
uint32_t version; /* Program version (6) */
|
||||
uint16_t crc16; /* What is this? */
|
||||
uint16_t skip; /* see propsal.txt */
|
||||
|
||||
prog_section statements; /* prog_section_statement */
|
||||
prog_section defs; /* prog_section_def */
|
||||
prog_section fields; /* prog_section_field */
|
||||
prog_section functions; /* prog_section_function */
|
||||
prog_section strings; /* What is this? */
|
||||
prog_section globals; /* What is this? */
|
||||
uint32_t entfield; /* Number of entity fields */
|
||||
} prog_header;
|
||||
|
||||
/*
|
||||
* Each paramater incerements by 3 since vector types hold
|
||||
* 3 components (x,y,z).
|
||||
|
|
Loading…
Reference in a new issue