Merge pull request #235 from asmundak/collapseduplicate
Export CollapseDuplicateProperties, Soong writedocs uses it
This commit is contained in:
commit
d444506bf6
1 changed files with 3 additions and 3 deletions
|
@ -228,7 +228,7 @@ propertyStructLoop:
|
||||||
for _, from := range mt.PropertyStructs {
|
for _, from := range mt.PropertyStructs {
|
||||||
for _, to := range collapsed {
|
for _, to := range collapsed {
|
||||||
if from.Name == to.Name {
|
if from.Name == to.Name {
|
||||||
collapseDuplicateProperties(&to.Properties, &from.Properties)
|
CollapseDuplicateProperties(&to.Properties, &from.Properties)
|
||||||
continue propertyStructLoop
|
continue propertyStructLoop
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -237,13 +237,13 @@ propertyStructLoop:
|
||||||
mt.PropertyStructs = collapsed
|
mt.PropertyStructs = collapsed
|
||||||
}
|
}
|
||||||
|
|
||||||
func collapseDuplicateProperties(to, from *[]Property) {
|
func CollapseDuplicateProperties(to, from *[]Property) {
|
||||||
propertyLoop:
|
propertyLoop:
|
||||||
for _, f := range *from {
|
for _, f := range *from {
|
||||||
for i := range *to {
|
for i := range *to {
|
||||||
t := &(*to)[i]
|
t := &(*to)[i]
|
||||||
if f.Name == t.Name {
|
if f.Name == t.Name {
|
||||||
collapseDuplicateProperties(&t.Properties, &f.Properties)
|
CollapseDuplicateProperties(&t.Properties, &f.Properties)
|
||||||
continue propertyLoop
|
continue propertyLoop
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue