Commit Graph

27 Commits

Author SHA1 Message Date
Ed_
1c133bfc8d Massive total progress on c_library generation: (Summary of last 3 WIP commits)
- No longer using GEN_API_C_* macros as C-library wont need them and if you need C linkage there is no need to use the c++ library.
- GEN_C_LIKE_CPP replaces GEN_SUPPORT_CPP_MEMBER_FEATURES && GEN_SUPPORT_CPP_REFERENCES
  a. If users don't want to use member functions, function overloading, or referencese they can just this one macro to before including the library.
- Enums aren't accomodated in C++ sources, they entirely converted in c_libray.cpp
- ast.hpp now properly generates with C variant
- Fully prepared code_types.hpp for C library gen (not tested yet)
- Generated enums managed by helper.hpp now properly generate for C library.
2024-12-07 17:58:56 -05:00
Ed_
451b71884c WIP: Broken af 2024-12-07 17:17:02 -05:00
Ed_
4d638a7255 borken : lots of stuff changed, explaining in later commit...v 2024-12-07 00:21:09 -05:00
Ed_
a3e7ec4c72 successful compile of c_library for: platform, macros, basic_types, debug, and memory headers (and newly generated c-code) 2024-12-05 00:40:51 -05:00
Ed_
cae1555b11 wip having nasty parser issue (fixed nasty lexer bug) 2024-12-04 15:00:37 -05:00
Ed_
f7709bb64e more progress 2024-12-04 11:30:54 -05:00
Ed_
3a55af9ce4 WIP(broken): Converting base library to use c-linkage symbols only 2024-12-04 11:01:53 -05:00
Ed_
80cb3f4eca Significant progress reducing c++ feature usage in the library. 2024-12-01 18:50:37 -05:00
Ed_
8ef982003a Added is_body to AST and Code types 2024-12-01 12:48:58 -05:00
Ed_
fbdb870986 Finished first pass reviewing memory.hpp for C lib generation 2024-11-30 23:38:27 -05:00
Ed_
06deb1e836 memory.hpp no longer uses memory mappings by default 2024-11-30 17:18:49 -05:00
Ed_
34eec66f35 Array done 2024-11-30 13:14:47 -05:00
Ed_
4137ebfbd8 pool done (see previous commits for context) 2024-11-30 12:27:54 -05:00
Ed_
5958dd2055 Did arena and fixedarena changes (for reducing usage of member procs) 2024-11-30 12:16:01 -05:00
Ed_
163ad0a511 looking into removing "oop" features from base library
I want to make member functions an optional addition the user can generate a derivative library with.
The purpose is to simplify the implementation as to make generating a C-variant simpiler.

I also want to use it as a study to see how much simpiler it makes the library without having it.
2024-11-29 15:18:06 -05:00
Ed_
e3c2a577ba addded String::contains defs 2024-11-29 14:50:54 -05:00
Ed_
2e5e31ed3b gencpp : General refactors to dependencies
Mostly just cleanup and renaming of certain stuff (mostly in dependencies).

* Changed uw and sw to usize and ssize.
* Removed zpl_cast usage throughout dependencies
* No longer using GEN_DEF_INLINE & GEN_IMPL_INLINE
* header_start.hpp renamed to platform.hpp for depdendencies header.
2024-10-27 18:58:37 -04:00
Ed_
b8e1aa6eb7 WIP : Fixes and other changes
* Number literals weren't getting properly lexed
* Fixes for compiler errors with Unreal Engine configuration.
* Support for "post-name" macros in parameters
* Support for variables initializing directly using constructor syntax.
* Explicitly added inline keyword to header inlines for compiling compile library in multiple translation units.
2024-10-25 01:04:17 -04:00
Ed_
6ea40094ee More fixes from clang warnings. Parser::lex prep for changes
parse_static_assert now properly adds new-line to end of statement.

I'm going to end up making a static_assert ast... that or when the statement ast is made it will handle adding that newline.
2023-09-07 22:52:51 -04:00
Ed_
0a8d3bfc6a Added fixed arenas (just ergonomics) 2023-09-07 22:29:04 -04:00
Ed_
0197afd543 Changed how editor intellisense directives are handled for compoenents and dependencies
Didn't like the way I was processing them in scan_file.
2023-08-28 23:46:50 -04:00
Ed_
f9117a2353 Added zpl's ivrtual memory to dependencies (unused for now) 2023-08-23 11:07:43 -04:00
Ed_
db6e8b33eb got intellisense working for the most part...
VScode works withs some issues.
VS2022 fails.
10xEditor works fine.
JetBrains Rider fails due to it not supporting <push/pop>_macro pragmas
2023-08-21 23:07:03 -04:00
Ed_
5c47777972 compiles agian... 2023-08-21 21:40:23 -04:00
Ed_
050b00f28a WIP - Broken Compile : Added pragma once and includes to all files + Parser fixes, and String improvements
Adding the pragma once and includes the files broke compilation, still diagnosing why.

- Some string functions were moved to the cpp, still need to do some more evaluation of it and the containers...
- Added support for forceinline and neverinline to parsing (untested)
- Added support for specifiers in operator cast such as explicit, inline/forceinline/neverinline, etc.
    - Before it only support const.
    - Still need to support volatile.
- Forceinline was not supported at all for tokenization, fixed that.
2023-08-21 20:30:13 -04:00
Ed_
5d7dfaf666 Heavy refactor..
Isolating large macros to their own directory (components/temp).
- Plan is to remove them soon with proper generation.

Added additional component files, separating the old data_structures header for a set of ast headers.
Header_end also had its inlines extracted out.
Necessary to complete the macro isolation.

ZPL parser dependencies were removed from the core library along with builder, its now generated in bootstrap as pare of making a gen_builder set of files.

Singleheader will be changed in next few commits to reflect this as well (By making builder deps and components a conditional option).

Tests are most likely all broken for now.
2023-08-03 11:01:43 -04:00
Ed_
c5afede7b5 Reorganization of files, refactors, doc updates (WIP)
Removing the gen. namespace from the files for components, dependencies, and file_processors.
They are only necessary if the include directory is transparent, and in my case those are not.

Made a docs directory. I'm offloading information from the main readme to there along with additional informationn I end up elaborating on down the line.
Enum tables were moved to their own directory (project/enums).

Library will not compile for now. Major refactor occuring with parsing related components.
2023-07-29 05:52:06 -04:00