b2PolygonShape.AsEdge with buggy raycast. Use workaround:

http://code.google.com/p/box2d/issues/detail?id=74

For the box2dflash, here's the workaround:

Code:
         var shape:b2PolygonShape = //b2PolygonShape.AsEdge(currentPoint, newPoint);
            b2PolygonShape.AsOrientedBox(
            b2Math.SubtractVV(currentPoint, newPoint).Length() * 0.5,
            0.01,
            b2Math.MulFV(0.5, b2Math.AddVV(currentPoint, newPoint)),
            Math.atan2(b2Math.SubtractVV(currentPoint, newPoint).y, b2Math.SubtractVV(currentPoint, newPoint).x));
Thanks. This was already fixed in the C++ version.

Original thread: https://box2d.org/forum/viewtopic.php?t=4373