Joao Matos
40bfd65135
Revert "Extract current module as read-only property to CodeGenerator.Module."
...
This reverts commit d340de3afa .
9 years ago
Joao Matos
2ad1f8b001
Extract file preamble generation into CodeGenerator.
9 years ago
Joao Matos
d340de3afa
Extract current module as read-only property to CodeGenerator.Module.
9 years ago
Joao Matos
b49389e409
Rename CodeTemplate to CodeGenerator.
9 years ago
Dimitar Dobrev
87a75e3acd
Changed the generation of C++ for inlines not to rely on -fkeep-inline-functions.
9 years ago
Joao Matos
17d06ac0e5
Port class handling to visitor model in C# generator.
9 years ago
Joao Matos
08c089251a
Port declaration context handling to visitor model in C# generator.
9 years ago
Joao Matos
34ed304228
Renamed Template to CodeTemplate due to conflict with AST templates.
9 years ago
Joao Matos
c0d4aa3979
Modified templates to be visitors.
9 years ago
Joao Matos
70e4d3b3a4
Added a new overload to Template that takes a single translation unit.
9 years ago
Joao Matos
fbf43067d7
Refactor the diagnostics system.
9 years ago
Joao Matos
7a5c34e0bc
Refactor the block-based text generator into own class.
9 years ago
Dimitar Dobrev
1b41897172
Fixed the generated C# when a header and a contained name-space bear the same name.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
9 years ago
Dimitar Dobrev
05c4213c28
Revert "Fixed the adjustment of the instance in cases of multiple inheritance."
...
This reverts commit e43dd1c18f .
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
9 years ago
Joao Matos
4e48af9a4c
Remove the Driver dependency from the generators with a BindingContext.
10 years ago
Joao Matos
41719e641e
Rename IDiagnosticConsumer to IDiagnostics.
10 years ago
Dimitar Dobrev
3230f9037f
Minor fixes to handling arrays and std::string.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
10 years ago
Dimitar Dobrev
a4dfeb94be
Moved the marking of supported template specialisations to a pass.
...
This allows custom passes to add other specialisations to support.
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
10 years ago
Dimitar Dobrev
0e344b4b8a
Tested generation of C# comments at run-time.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
10 years ago
Dimitar Dobrev
c8397166ed
Optimised code generation when the option for auto-compilation is used.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
10 years ago
Dimitar Dobrev
c2202bbfc0
Removed the wrapping of comments because tools ignore empty lines.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
10 years ago
Dimitar Dobrev
ef4be0b959
Fixed the generation of code in a single file.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
12 years ago
Dimitar Dobrev
840ce34552
Added an option to generate a single source file per extension.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
Conflicts:
src/Generator/Driver.cs
src/Generator/Options.cs
12 years ago
Tomi Valkeinen
4e185973e5
Normalize all the line endings
...
Normalized all the line endings with:
git rm --cached -r .
git reset --hard
git add .
git commit -m "Normalize all the line endings"
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@iki.fi>
12 years ago
marcos henrich
b28ac8b304
Added delegate CheckGenerate that is called before on generate so the block text generation can be empty when needed.
12 years ago
marcos henrich
3237a7b421
Template method PopBlock now returns the active block.
12 years ago
marcos henrich
c061cf5be4
Added property IsEmpty to Block.
12 years ago
triton
86c651625c
Added a new block policy to only generate a block if the following is not empty.
12 years ago
Stephen Kennedy
0957843c4d
Unify debugging output
...
Route all debugging output through Driver.Diagnostics
12 years ago
triton
b9e57dba78
Re-write the blocks generator again (thanks to esdrubal for helping me with the new design).
...
Now the whitespace/new line handling is done by the output generator per block, instead of having to be managed manually which could lead to all sorts of messy output without being extra careful.
Also the new system limits the usage of generics since C# was too limited to design it properly, and it ended up being more trouble than it was worth. The blocks kinds were also changed to be const int, since enums are very hard to extend and made it hard to provide a common interface for dealing with blocks.
13 years ago
triton
68ddfbdd6f
Move the AST project to the CppSharp.AST namespace.
13 years ago
triton
6308cf4c3c
Added a new templating system based on typed "text blocks", allowing a lot more customization after the initial text is generated.
...
The design might still change a bit in the future, but this is a good first step in getting things in the final direction without having to change too much the current generators.
13 years ago
triton
cbe05e6253
Cleaned up TextTemplate class.
13 years ago
triton
cb85d8ead3
Move some helper functions out of the template and into an helpers class.
13 years ago
triton
cc8f7cd1db
Renamed Cxxi references to CppSharp.
13 years ago
triton
cb7bc5aa69
Use var initialization instead of explicitly declaring the type.
13 years ago
triton
d18998557e
Added an helper method to check for ignored functions.
13 years ago
triton
6ad3cb59f6
Move helper ignore checker methods to Template.cs so they can be used by different generators.
13 years ago
triton
3f3b9f4aa3
Renamed the translation unit property to follow conventions.
13 years ago
triton
7247d039d0
Extract the generic text generating helper code into its own class.
13 years ago
triton
34eeb8e052
Renamed Options to DriverOptions.
13 years ago
triton
f5fcef50f1
Massive update to the codebase.
...
- Removed reliance on T4 text templates that were proving to be a portability problem.
- Refactored the generator design to make a little more sense.
- Moved the examples to their own projects.
- Improved the build system to only use one unified output folder.
- Added much improved template support.
- Added work-in-progress C++/CLI generator backend.
- Added the concept of type maps.
13 years ago