Releases: skippuku/introcity
Releases · skippuku/introcity
(Beta) 0.4
NEW ATTRIBUTE FEATURES
new attribute category: 'type'
new built-in attributes: 'imitate', 'header'
new attribute traits: '@transient', '@imply'
removed attribute: 'type'
INTROLIB
better support for wider range of compilers by adhering strictly to
the C99 standard.
intro.h now has a version that intro will check and compare to its own
version to help identify errors that stem from version mismatching
(Beta) 0.3
0.3 (Beta)
SINGLE FILE INTROLIB
intro.h, introlib.c, and intro_imgui.cpp have been combined into just
intro.h with implementations enabled when macros INTRO_IMPL or
INTRO_IMGUI_IMPL are defined.
The file compiles as both C99 and C++11. (Dear ImGui procedure
implementations only compile as C++).
Dependencies to STB libraries have been removed in intro.h to avoid
linking conflicts.
intro.h now includes a copy of the MIT license for convenience.
NEW ATTRIBUTE FEATURES
Attributes can now be applied to enum values.
New namespacing rules: formerly, an attribute could be referenced
without a namespace if there were no conflicts. This behavior has been
revoked as it leads to ambiguity and unexpected problems as more
attributes are added. To replace this behavior, labels have been
added which allow namespaces to be explicity implied.
V 0.2: (only gui_max doesn't require its namespace in this case)
float some_var I(i_id 5,
gui_min 0.0, max 100.0,
my_min -1, my_id 4)
V 0.3: (no ambiguity)
float some_var I(id 5,
gui: min 0.0, max 100.0,
my: flag, id 4)
Bitfield sizes are now available as the built-in 'bitfield'
arrtribute.
New @propagate trait: declares that an attribute is passed down to
typedef's and members of that type. Formerly, this was the default
for every attribute and could not be disabled.
Attribute terminology has been reworked as it was inconsistent.
Built-in attributes beginning with 'i_' have been moved into the global
attribute namespace.
The built-in 'default' attribute has been renamed to 'fallback'.
The handle used to get attribute information (type->attr /
member.attr) is now a distinc type: 'IntroAttributeDataId'.
OTHER
Const is no longer ignored by the compiler.
This was done in order to facilitate binding generation.
The expression parser now supports floating-point types.
The preprocessor now supports __has_include and __has_include_next.
The proprocessor now supports defining a macro value on the
command-line with '-DNAME=VALUE'.
Various internal fixes and improvements
(Beta) 0.2
From doc/changelog.txt:
API SIMPLIFICATION
- IntroType changes:
type->i_struct->count_members => type->count
type->i_struct->members => type->members
type->i_enum->count_members => type->count
type->i_enum->members => type->values
type->i_enum->is_flags => type->flags & INTRO_IS_FLAGS
type->i_enum->is_sequential => type->flags & INTRO_IS_SEQUENTIAL
type->array_size => type->count
intro_size(type) => type->size
<unavailable> => type->align
if (type->of) => if (intro_has_of(type))
('of' now shares storage with other fields)
- IntroFunction changes:
func->type->args->count => func.count_args
func->type->args->types => func.arg_types
func->type->of => func.return_type
- Removed IntroStruct, IntroEnum, and IntroTypePtrList
- Removed all usage of flexible array members in introlib
- New IntroContainer system provides a simple API for recursively working
on data while retaining context for how the data was accessed.
CITY IMPROVEMENTS
- support for unions (using the "when" attribute)
- much better handling of pointers
- city file data can now be discarded after load
- reduction in serialized data size
ATTRIBUTES
- Support for struct values including C99 style initialization
- New "expr" attribute type generates bytecode for expressions
that can access struct/union members.
- The "length" attriubte is now an expression. This is useful if the size
of data is dependent on multiple variables, for example
"I(length map_width * map_height)" could be used to define the size of
a tilemap buffer.
- New builtin attribute "when" for using an expression to dynamically
determine when a struct/union member is valid.
- The "string" attribute type has been removed. Use "value(char *)" instead.
NEW PARSER FEATURES
- '#prama intro' can be used to control what parts of a file should have
information generated
- push, pop
- enable [x], disable [x] where x is either omitted or one of the
following: functions, macros, all, includes, system
- Macro information generation (use pragma "enable macros")
- Vim syntax generation with --gen-vim-syntax
- Performance metrics report with option '-V'
IMPLEMENTATION CHANGES
- Struct member offsets are now known at parse time.
- Enables more features in the parser.
- NOTE: pack(x), __attribute__((aligned(x))), etc. are not yet implemented
- Generated headers are much more concise (no more offsetof's)
- Files are now tokenized all at once. Previously, the preprocessor and
parser would tokenize as needed. This simplifies the preprocessor and
parser.
OTHER
- intro_print() improvements
- Miscellaneous fixes and improvements