Joao Matos
07e3113cef
Added a parsing option to skip gathering of native layout info.
...
The way we get AST layout info from Clang sometimes causes us to crash deep inside Clang.
While layout info is needed for binding C++ code, it is not usually necessary for more generalized AST consumption tasks, so add this option to make parsing code less problematic, until we are able to get the bugs tracked down.
6 years ago
Dimitar Dobrev
e203463a9d
Added an option for skipping private declarations.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
7 years ago
Dimitar Dobrev
fceb204a98
Fixed the generated C# for members of types nested in templates.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
450a26a443
Revert "Removed an unused field and redundant parameters from the parser."
...
This reverts commit 51a109d2db
.
# Conflicts:
# src/CppParser/CppParser.cpp
# src/CppParser/CppParser.h
# src/CppParser/Parser.cpp
# src/CppParser/Parser.h
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
33bc64ad9a
Reused the parsing of headers to get the target info as well.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
3abe0e5195
Deleted an useless field from the parser options.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
28f42bb1c7
Deleted useless fields from the parser.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
51a109d2db
Removed an unused field and redundant parameters from the parser.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Dimitar Dobrev
c61c989460
Added an option for specifying STD types to bind.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
8 years ago
Mohit Mohta
3e8b15c42c
Made the C/C++ language switches adjustable in managed code. ( #895 )
8 years ago
Mohit Mohta
65d6c49e1b
Making the code run properly from a different working directory ( #891 )
8 years ago
Mohit Mohta
3699574983
Removed the macros in C++ AST for std::string because we can marshal it ( #866 )
8 years ago
Dimitar Dobrev
ee171eb9fa
Freed up the native parser options when done with.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
9 years ago
Dimitar Dobrev
dbb3182b44
Fixed all warnings in our C++ part.
9 years ago
Dimitar Dobrev
0a5c73dc48
Added explicit GNU versions to the language options of the parser.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
9 years ago
Dimitar Dobrev
749c2b17ec
Renamed ParserOptions to CppParserOptions and ParserOptions2 to ParserOptions.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
9 years ago
Dimitar Dobrev
dc84c9b765
Added an option to parse all headers at once - much faster.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@protonmail.com>
9 years ago
triton
15db2c04ad
Added a ParserTargetInfo option to the parser options.
...
We'll this to be able to override target details on Clang.
10 years ago
Dimitar Dobrev
643776b70e
Enabled the addition of undefines in the options.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
11 years ago
Dimitar Dobrev
548f0feb55
Added an option for the language version.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
11 years ago
Dimitar Dobrev
21cf90411a
Fixed a few warning caused by classes forwarded as structs.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
11 years ago
Dimitar Dobrev
5523a83b29
Converted all "complex" (for example participating in class hierarchies) data type to classes.
...
Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
11 years ago
Tomi Valkeinen
6536beb0ab
CppParser: fix warning about Parser
...
Fix the following warning by renaming ParserResult::Parser to
CodeParser.
In file included from ../../../src/CppParser/Parser.h:16:0,
from ../../../src/CppParser/Comments.cpp:8:
../../../src/CppParser/CppParser.h:86:13: warning: declaration of ‘CppSharp::CppParser::Parser* CppSharp::CppParser::ParserResult::Parser’ [-fpermissive]
Parser* Parser;
^
../../../src/CppParser/CppParser.h:73:8: warning: changes meaning of ‘Parser’ from ‘struct CppSharp::CppParser::Parser’ [-fpermissive]
struct Parser;
^
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@iki.fi>
11 years ago
triton
55f4b849c7
Explicitly construct the parser and keep it in ParserResult.
...
This fixes some non-deterministic behavior in the new parser but it means we are keeping around all the memory for parsing until the end of the process. This is a bit messy right now but at least we keep the API compatible between parsers. After all the new parser bugs are squashed, this will be reworked.
11 years ago
triton
012efc0948
Minor formatting fixes.
11 years ago
triton
aa3e8dd5bd
Explicitly define some copy constructors to work around missing symbols.
...
We should not need to do this, but Clang ignores the GCC flag "-fkeep-inline-functions" which we need to actually get these to be properly exported in a library...
11 years ago
triton
48216a5bd4
Added an explicit constructor to ParserDiagnostic to fix missing symbols.
11 years ago
triton
71a875d6b9
Added missing GetTargetInfo to CppParser.
11 years ago
Øystein Krog
a268eb1875
Add new GetTargetInfo() method in parsers, that exposes information about type sizes and alignment.
12 years ago
triton
45b110e739
Added arguments options support to pass custom Clang options to the parser.
12 years ago
triton
b11644de19
Converted the rest of the inline declarations to be defined outside the header.
12 years ago
triton
6edd10b514
Move CppParser method definitions out of the headers and into the source file.
...
This is a workaround for missing symbols when P/Invoking on the Mac for instance. There should be a working "-fkeep-inline-functions" switch available in Clang but upon reading the source code, it does not do anything besides consuming the option (not even a warning!).
12 years ago
triton
64e75fb0a6
Reworked the C++ parser structures to use some helper macros to ease the bindings.
12 years ago
triton
e7ab3ded16
Fixed wrong usage of token pasting operator ##.
12 years ago
triton
b3bc8706a0
Changed CppParser to use macros to define the containers.
...
This way we can also define some helper methods to consume these from C#.
12 years ago
triton
4a29db6bcd
Revert "Fixed bug caused by a type in the new parser."
...
This reverts commit f1f6c2e5e9
.
12 years ago
triton
f1f6c2e5e9
Fixed bug caused by a type in the new parser.
12 years ago
triton
f11d7a3fc0
Rearranged members order in ParserOptions.
12 years ago
triton
1d15feaea7
Added ASTContext to ParserOptions.
12 years ago
triton
d3a25d69ea
Initialize ParserOptions members in its default constructor.
12 years ago
triton
078b71be45
Updated the C++ parser project to the new ASTContext class.
12 years ago
triton
b3f41256e3
Moved the native AST declarations to their own namespace.
12 years ago
triton
4e1d34b98b
Use fully qualified names in AST headers.
12 years ago
triton
62839a3f0a
Added the new C++/CLI free parser.
...
I benchmarked it and it's about the same speed in Release mode (maybe a bit faster) but 3x slower in VS Debug mode due to all the STL usage.
12 years ago