Menu

#1167 syntax error when parsing complex default values

open
parsing (146)
5
2024-01-24
2011-05-19
No

Parser fails at the following code:

struct Inner
{
double d() const;
};
struct Outer
{
static Inner i;
};
void f(double param = Outer::i.d());

Discussion

  • Olly Betts

    Olly Betts - 2022-01-25

    Still present in current git master.

     
  • Olly Betts

    Olly Betts - 2022-02-03

    I'm just about to merge a fix for the function call part but the namespace part isn't handled yet (so i.d() will soon work).

     
  • Olly Betts

    Olly Betts - 2024-01-24

    Still present in current git master (shortly after 4.2.0).

    SWIG now handles both these cases:

    void f(double param = i.d());
    
    void f(double param = Outer::d());
    

    However the case reported here with both a namespace and an object is still not handled.

     

    Last edit: Olly Betts 2024-01-24

Log in to post a comment.