Skip to content

"Create missing overrides" generates invalid code on Windows #2766

@Maverick-I0

Description

@Maverick-I0

I was creating a CustomShapeBorder by extending the ShapeBorder class, then when I used quickfix to create the 5 @overrides using the quickfix from VSCode. 3 of 5 overrides the getInnerPath, getOuterPath and paint had syntax errors in their parameters.

ezgif com-video-to-gif

the code is as follows with the errors:

class CustomCardShapeBorder extends ShapeBorder{
  @override
  // TODO: implement dimensions
  EdgeInsetsGeometry get dimensions => throw UnimplementedError();

  @override
 // error: parameter with ${3|
  Path getInnerPath(Rect rect${3|, {TextDirect,TextDirection,Object|}ion textDirection}) {
      // TODO: implement getInnerPath
      throw UnimplementedError();
    }
  
    @override
// error: parameter with closing }  in the end of text direction
    Path getOuterPath(Rect rectrection textDirection}) {
      // TODO: implement getOuterPath
      throw UnimplementedError();
    }
  
    @override
// error: parameter with speling errors and closing }  in the end of text direction
    void paint(Canvas canvas, Rect rectxtDirection textDirection}) {
      // TODO: implement paint
    }
  
    @override
    ShapeBorder scale(double t) {
    // TODO: implement scale
    throw UnimplementedError();
  }
 
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions