Why isn't UIButton returning correct constraints?
问题 In my code below: I have 5 buttons added into a vertical scrollView. Each button is constrained to the scrollViews's top + 20 ,leading, trailing edges and its height. I have created a b1HeightConstraint variable. It's there to hold the heightConstraint of the b1 button. In a button click, I'm trying to remove this constraint. Yet I'm facing an odd issue: When I log the constraints I only see 2 constraints, even though I've added 4 constraints to it. My the view debug hierarchy is like below: