File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -128,7 +128,7 @@ extension FFMSwift2JavaGenerator {
128128 let mainSymbolSourceModules = Set (
129129 self . lookupContext. symbolTable. importedModules. values. filter { $0. alternativeModules? . isMainSourceOfSymbols ?? false } . map ( \. moduleName)
130130 )
131-
131+
132132 for module in self . lookupContext. symbolTable. importedModules. keys. sorted ( ) {
133133 guard module != " Swift " else {
134134 continue
@@ -167,9 +167,13 @@ extension FFMSwift2JavaGenerator {
167167 }
168168 }
169169
170- printer. print ( " #else " )
171- printer. print ( " import \( module) " )
172- printer. print ( " #endif " )
170+ if ( importGroups. keys. isEmpty) {
171+ printer. print ( " import \( module) " )
172+ } else {
173+ printer. print ( " #else " )
174+ printer. print ( " import \( module) " )
175+ printer. print ( " #endif " )
176+ }
173177 }
174178 printer. println ( )
175179 }
You can’t perform that action at this time.
0 commit comments