mirror of
https://github.com/Ed94/gencpp.git
synced 2025-01-08 16:03:32 -08:00
Ed_
9b6dc3cbd8
The NumEntries checks need to be deferred until the end as a final unresolved check on valdiation. As if there really is a discrepancy of entires it should be revealed by the specific entry failing. Right now the latest failure with the single header check involves a define directive specifically the define does omit whitespace properly and so the check interprets the different cached content to be non-equivalent. This will happen with all unvalidated aspects of the AST ( expressions, function bodies, etc ) There are two ways to resolve, either make an AST that can tokenize all items (not realistic), or I need to strip non-syntax important whitespace and then cache the string. This would mean removing everything but a single whitespace for all content within a content string. Otherwise, I would have to somehow make sure the content of the string has the exact formatting between both files for the definitions that matter. AST types with this issue: * Define Directive * Pragma Directive * Comment * Execution * Platform Attributes * Untyped Comments can technically be left unverified as they do not matter semantically. When the serialization is first emitted, the content these strings should for the most part be equivalent. However I do see some possible failures for that if a different style of bracket placment is used (between the serialization). At that point what I could do is just leave those unverified and just emit the content to the user as warning that the ast and the other compared could not be verified. Those technically can be handled on a per-eye basis, and worst case the tests with the compiler will in the determine if any critical defintions are missing for the user. |
||
---|---|---|
.. | ||
gen | ||
ast_case_macros.cpp | ||
ast_types.hpp | ||
ast.cpp | ||
ast.hpp | ||
header_end.hpp | ||
header_start.hpp | ||
inlines.hpp | ||
interface.cpp | ||
interface.hpp | ||
interface.parsing.cpp | ||
interface.untyped.cpp | ||
interface.upfront.cpp | ||
src_start.cpp | ||
static_data.cpp | ||
types.hpp |