Why rib is not working with curved edge????

I modeled a simple part where I wanna put a rib as shown in red line. It feels like very straight forward way.

I made a sketch on right plane and draw a line from top edge. when the line not touching the curve edge, just the horizontal plane, then its worked fine. But leaving a gap from edge.

But when the line was touching the curved edge like the image below the rib tool was showing rebuild error message and did not work properly.

I don't know why is it happening, please somebody provide solution. Is there any solution to do it with rib tool? I'm using Solidworks 2017.

SolidworksModeling And Assemblies