We should investigate if we can consolidate and extract common logic from the field sorting methods in FieldLayoutBuilder so that we don't have duplicate code in both places.
Methods:
FieldLayoutBuilder::inline_class_field_sorting()
FieldLayoutBuilder::regular_field_sorting()
Methods:
FieldLayoutBuilder::inline_class_field_sorting()
FieldLayoutBuilder::regular_field_sorting()