markupAvailable top-level property
Whether the loaded native library carries the markup symbols. False in flutter_runtime builds, where rml is excluded (editor-only); callers (and tests) must check before using revToRml or rmlToRev -- the lazily-initialized lookups below throw on first use otherwise. Both directions are probed: they come from one translation unit, so a library carrying only one of them is a stale build, and failing closed sends callers down their fallback instead of throwing.
Implementation
final bool markupAvailable = () {
try {
for (final symbol in ['freeRmlExport', 'freeRmlCompile']) {
_nativeLib.lookup<NativeFunction<Void Function(Pointer<Void>)>>(symbol);
}
return true;
} on ArgumentError {
return false;
}
}();