Are Walls Detected by RoomPlan Sorted?

I'm just curious if anybody knows if under the hood RoomPlan is applying any sort of sorting to the CapturedRoom.walls array. Like does RoomPlan try to sort the walls so they complete a loop? Or are walls simply appended to the back of the array as they are detected?

Are Walls Detected by RoomPlan Sorted?
 
 
Q