{"record":{"id":"b6c84e525a5840fe","repo":"DioxusLabs/dioxus","slug":"unsupported-abi-expected-swift-or-kotlin","errorCode":null,"errorMessage":"Unsupported ABI: {}. Expected 'Swift' or 'Kotlin'","messagePattern":"Unsupported ABI: (.+?)\\. Expected 'Swift' or 'Kotlin'","errorType":"validation","errorClass":"syn::Error","httpStatus":null,"severity":"error","filePath":"packages/manganis/manganis-macro/src/ffi.rs","lineNumber":290,"sourceCode":"        let lit: LitStr = input.parse()?;\n        Ok(FfiAttribute {\n            source_path: lit.value(),\n        })\n    }\n}\n\nimpl FfiBridgeParser {\n    /// Parse the attribute and item together\n    pub fn parse_with_attr(attr: FfiAttribute, item: ItemForeignMod) -> syn::Result<Self> {\n        let source_path = attr.source_path;\n\n        // Determine the ABI\n        let abi = match &item.abi.name {\n            Some(name) => match name.value().as_str() {\n                \"Swift\" => ForeignAbi::Swift,\n                \"Kotlin\" => ForeignAbi::Kotlin,\n                other => {\n                    return Err(syn::Error::new(\n                        name.span(),\n                        format!(\"Unsupported ABI: {}. Expected 'Swift' or 'Kotlin'\", other),\n                    ));\n                }\n            },\n            None => {\n                return Err(syn::Error::new(\n                    item.abi.extern_token.span,\n                    \"Expected ABI string (e.g., extern \\\"Swift\\\")\",\n                ));\n            }\n        };\n\n        let mut types = Vec::new();\n        let mut functions = Vec::new();\n\n        for item in &item.items {\n            match item {","sourceCodeStart":272,"sourceCodeEnd":308,"githubUrl":"https://github.com/DioxusLabs/dioxus/blob/24f6a829df0dfa203961a98ea4cae21c2ff27e28/packages/manganis/manganis-macro/src/ffi.rs#L272-L308","documentation":"`parse_with_attr` inspects the extern block's ABI name and only supports `extern \"Swift\"` and `extern \"Kotlin\"`; any other ABI string produces this compile error naming the unsupported ABI and the two valid options.","triggerScenarios":"Thrown at packages/manganis/manganis-macro/src/ffi.rs:290 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use extern \"Swift\" or extern \"Kotlin\" as the ABI; other ABI strings are not supported."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"24f6a829df0dfa203961a98ea4cae21c2ff27e28","analyzedAt":"2026-08-23T07:10:14.078Z","contentChangedAt":"2026-08-23T07:10:14.078Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}