Thanks,
Taras
> ------------------------------------------------------------------------
>
> _______________________________________________
> dev-static-analysis mailing list
> dev-stati...@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-static-analysis
>
> Hi Daniel,
> This sounds useful, but the mailing list strips attachments.
>
> Please file a bug and attach
https://bugzilla.mozilla.org/show_bug.cgi?id=500078
So, speaking of language bindings, the ability to create directories
would be useful. Would anyone object if I added a mkdir style
function? Also, how does one identify the linkage type from within
dehydra.c (as in extern "C" { ...)? Those two bits (and the patch)
are the last pieces I need to finish my automatic C/C++ -> Java
language binding generator.
--
Daniel
> So, speaking of language bindings, the ability to create directories
> would be useful. Would anyone object if I added a mkdir style
> function? Also, how does one identify the linkage type from within
I suspect that it would be more productive to add a generic system()
function rather than mkdir and whatever else people need.
system(['mkdir', '/path/foo/bar']);
> dehydra.c (as in extern "C" { ...)? Those two bits (and the patch) are
> the last pieces I need to finish my automatic C/C++ -> Java language
> binding generator.
I don't think that's exposed through dehydra, although it's likely you can
reach it via treehydra somehow... you probably need to read cp-tree.h to
find the correct macro and translate that into JS.
--BDS
DECL_EXTERN_C_P in cp-tree.h is what you want. In general tree.def,
cp-tree.def and corresponding .h files are good to look at.
I'll take a patch for an isExternC attribute on variables.
Taras
> I'll take a patch for an isExternC attribute on variables.
> https://bugzilla.mozilla.org/show_bug.cgi?id=500596
Should (Will ?) the attribute be set when compiling C files ?
I tend to think that yes, it will probably make easier the live of
peoples whose tree is a mix of C and C++, and aren't those the ones
primarily concerned by it ?
I still haven't heard of anybody using dehydra C in the wild. Can't
seriously consider C-related issues until I see some bug/success reports.
Taras
Tarmik above seemed to be willing to use it, but we apparently have lost
him :-(
I don't know. At the moment it depends entirely on if the compiler
marks it as such when compiling C. I'll test it.
Also, let me actually get this patch out. Been very busy with family.
--
Daniel
> Should (Will ?) the attribute be set when compiling C files ?
Yes. It does. I added a test case that verifies this. I think it
should because GCC does and it can substantially simplify the
procedure for writing language bindings (which is my primary interest).
--
Daniel