July 20, 2012 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jacob Carlborg | On 7/7/12, Jacob Carlborg <doob@me.com> wrote:
> snip
Nice work!
Can I ask you something? Do you know if (lib)clang exports typeinfo
for default values? For example:
namespace Foo
{
enum En
{
Val1,
Val2
};
}
void test(int x = Foo::Val1) { }
'x' has typeinfo (it's an int), but I'm interested in the typeinfo for
the default value "Foo::Val1". In other tools (like gccxml) the
default value is exported as a string which makes generating default
values in D hard (not impossible but just hard).
|
July 20, 2012 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Andrej Mitrovic | On 2012-07-20 15:04, Andrej Mitrovic wrote: > Nice work! Thanks. > Can I ask you something? Do you know if (lib)clang exports typeinfo > for default values? For example: > > namespace Foo > { > enum En > { > Val1, > Val2 > }; > } > > void test(int x = Foo::Val1) { } > > 'x' has typeinfo (it's an int), but I'm interested in the typeinfo for > the default value "Foo::Val1". In other tools (like gccxml) the > default value is exported as a string which makes generating default > values in D hard (not impossible but just hard). Don't know, sorry. I have only worked with C and Objective-C code. I can see if I can find out. -- /Jacob Carlborg |
July 20, 2012 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Andrej Mitrovic | On 2012-07-20 15:04, Andrej Mitrovic wrote: > On 7/7/12, Jacob Carlborg <doob@me.com> wrote: >> snip > > Nice work! > > Can I ask you something? Do you know if (lib)clang exports typeinfo > for default values? For example: > > namespace Foo > { > enum En > { > Val1, > Val2 > }; > } > > void test(int x = Foo::Val1) { } > > 'x' has typeinfo (it's an int), but I'm interested in the typeinfo for > the default value "Foo::Val1". In other tools (like gccxml) the > default value is exported as a string which makes generating default > values in D hard (not impossible but just hard). In libclang, the kind of "Foo::Val1" in the above example is: CXCursor_FirstExpr -> CXCursor_DeclRefExpr -> CXCursor_NamespaceRef. What I did here was I checked the kind of "Foo::Val1" cursor, drilled down into the cursor children as far as possible. Cursor kinds: http://clang.llvm.org/doxygen/group__CINDEX.html#gaaccc432245b4cd9f2d470913f9ef0013 -- /Jacob Carlborg |
July 20, 2012 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jacob Carlborg | On 7/20/12, Jacob Carlborg <doob@me.com> wrote:
> In libclang, the kind of "Foo::Val1" in the above example is:
>
> CXCursor_FirstExpr -> CXCursor_DeclRefExpr -> CXCursor_NamespaceRef.
>
> What I did here was I checked the kind of "Foo::Val1" cursor, drilled down into the cursor children as far as possible.
>
> Cursor kinds:
>
> http://clang.llvm.org/doxygen/group__CINDEX.html#gaaccc432245b4cd9f2d470913f9ef0013
Cool, this will come in handy. Thanks.
|
July 22, 2012 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Andrej Mitrovic | On 2012-07-20 16:58, Andrej Mitrovic wrote: > Cool, this will come in handy. Thanks. If your interested you can help out with DStep, add C++ support or similar :) -- /Jacob Carlborg |
January 30, 2015 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jacob Carlborg | Please, compile for Win32. |
January 30, 2015 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to data man | On 2015-01-30 03:32, data man wrote: > Please, compile for Win32. This issue has been libclang. Might be easier now that DMD supports Win32 COFF. -- /Jacob Carlborg |
January 30, 2015 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jacob Carlborg | Thank you!
I'm working on an adaptation of 7-zip for Phobos, and I very hope that DStep help me with this!
P.S. Sorry for my runglish!
On Friday, 30 January 2015 at 07:48:40 UTC, Jacob Carlborg wrote:
> On 2015-01-30 03:32, data man wrote:
>> Please, compile for Win32.
>
> This issue has been libclang. Might be easier now that DMD supports Win32 COFF.
|
January 30, 2015 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Jacob Carlborg | On Sunday, 8 July 2012 at 20:01:07 UTC, Jacob Carlborg wrote: > Do you have a suggestion? Just brain storming (i.e. some output may be nonsense): - dimp [1] (D + import) [2] - dimpc (pronounced "dimps") - dimplink - cimport - cimpleD - DiCe (D importing C external / extensions - you would want the 'e' at the end ;)) - CeeD (as in "seed") - CeDe Just think of some words starting with 's', 'c' or 'd' (or ending in 'd') PS "cd" won't work :) PPS Great project! [1] https://en.wiktionary.org/wiki/dimp#English [2] in case it will go beyond C/Obj-C, we need no reference to C |
January 30, 2015 Re: DStep - Bindings Generator 0.0.1 | ||||
---|---|---|---|---|
| ||||
Posted in reply to Chris | On 2015-01-30 13:01, Chris wrote: > Just brain storming (i.e. some output may be nonsense): > > - dimp [1] (D + import) [2] > - dimpc (pronounced "dimps") > - dimplink > - cimport > - cimpleD > - DiCe (D importing C external / extensions - you would want the 'e' at > the end ;)) > - CeeD (as in "seed") > - CeDe I think I'm going to stick with DStep. > [1] https://en.wiktionary.org/wiki/dimp#English > [2] in case it will go beyond C/Obj-C, we need no reference to C It will hopefully support C++ as well. -- /Jacob Carlborg |
Copyright © 1999-2021 by the D Language Foundation