Re: request: add const member function flag for C++

"Eric M. Ludlam" <[email protected]>
Newsgroups gmane.emacs.cedet
Message-ID <[email protected]>
On 09/04/2014 08:16 AM, Oleh wrote:
> Hi all,
>
> I'd like to bring to your attention one feature that's missing from C++ parser.
> This is the example source file:
>
> #+begin_src C++
> class ABC
> {
>      int value() const;
> };
> #+end_src
>
> `bovinate' returns:
>
>      (("ABC" type
>              (:members
>               (("value" function
>                         (:prototype-flag t :type "int")
>                         (reparse-symbol classsubparts)
>                         #<overlay from 17 to 35 in test.cc>))
>               :type "class")
>              nil #<overlay from 1 to 38 in test.cc>))
>
> while I'd like it to return:
>
>      (("ABC" type
>              (:members
>               (("value" function
>                         (:prototype-flag t :constant-flag t :type "int")
>                         (reparse-symbol classsubparts)
>                         #<overlay from 17 to 35 in test.cc>))
>               :type "class")
>              nil #<overlay from 1 to 38 in test.cc>))
>
> The difference is ":constant-flag t". The constant-flag is already implemented
> for variables, but not yet for member functions.

Hi Oleh,

You found a bug, where the parser was actually parsing and saving all 
this correctly, but the return-list wasn't splicing the value back into 
the rule result correctly.  I fixed the problem, and you will now find 
that :methodconst-flag is now set to t.  This also fixes a similar 
problem with :reentrant flag.

Eric

------------------------------------------------------------------------------
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.