On Wed, Feb 22, 2017, at 19:58, Gustavo Sverzut Barbieri wrote:
> On Wed, Feb 22, 2017 at 2:29 PM, Daniel Kolesa <[email protected]>
> wrote:
> > q66 pushed a commit to branch master.
> >
> > http://git.enlightenment.org/core/efl.git/commit/?id=7249dd94ab41145c9a137e9420ea654955de39ce
> >
> > commit 7249dd94ab41145c9a137e9420ea654955de39ce
> > Author: Daniel Kolesa <[email protected]>
> > Date:   Wed Feb 22 18:29:07 2017 +0100
> >
> >     docgen: add a way to get numerical id of a function
> > ---
> >  src/scripts/elua/apps/docgen/doctree.lua | 6 ++++++
> >  1 file changed, 6 insertions(+)
> >
> > diff --git a/src/scripts/elua/apps/docgen/doctree.lua 
> > b/src/scripts/elua/apps/docgen/doctree.lua
> > index 1a3061b..a3a7573 100644
> > --- a/src/scripts/elua/apps/docgen/doctree.lua
> > +++ b/src/scripts/elua/apps/docgen/doctree.lua
> > @@ -326,6 +326,8 @@ local func_type_str = {
> >      [eolian.function_type.METHOD] = "method"
> >  }
> >
> > +local ffi = require("ffi")
> > +
> >  M.Function = Node:clone {
> >      -- function types
> >      UNRESOLVED = eolian.function_type.UNRESOLVED,
> > @@ -443,6 +445,10 @@ M.Function = Node:clone {
> >
> >      is_same = function(self, other)
> >          return self.func == other.func
> > +    end,
> > +
> > +    id_get = function(self)
> > +        return tonumber(ffi.cast("uintptr_t", self.func))
> 
> not good...use a hash of function name, at least will survive rebuilds

Not the point, it's not meant to survive anything or be written
anywhere. It's just to get a unique numerical id for a single run of the
docgen, which can be used as hashtable key (i will need this to generate
the final list you wanted, but I need to change a few other things
before that, which is why I haven't done it yet... I'm looking into it)

D5

> 
> 
> -- 
> Gustavo Sverzut Barbieri
> --------------------------------------
> Mobile: +55 (16) 99354-9890
> 
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> _______________________________________________
> enlightenment-devel mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
enlightenment-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to