---
schema_version: "1"
id: 10d8893cce902d49f895bc1b0e79b84512bf57e7a1010823308815200e17777e
title: evaluateCompatibilityFlag
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/dataweave/2.9/dw-core-functions-evaluatecompatibilityflag.md
canonical_url: https://docs.mulesoft.com/dataweave/2.9/dw-core-functions-evaluatecompatibilityflag
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 0542356a39c3fa579f66dede9fd6e2907ea20c6fd908134d3da48a2db1722534
description: MuleSoft Documentation Site
release: "2.9"
latest: false
---
---
product: DataWeave
version: 2.9
---

# evaluateCompatibilityFlag

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

## evaluateCompatibilityFlag(flag: String): Boolean

Returns the value of the compatibility flag with the specified name.

_Introduced in DataWeave version 2.5.0._

### Parameters

<table><colgroup><col> <col> <col></colgroup><thead><tr><th>Name</th><th>Type</th><th>Description</th></tr></thead><tbody><tr><td><p><code>flag</code></p></td><td><p>String</p></td><td><p>The name of the compatibility flag to evaluate.</p></td></tr></tbody></table>

### Example

This example gets the `com.mulesoft.dw.xml_reader.honourMixedContentStructure` compatibility flag
value in the current DataWeave version.

#### Source

```DataWeave
%dw 2.0
output application/json
---
{
  "com.mulesoft.dw.xml_reader.honourMixedContentStructure": evaluateCompatibilityFlag("com.mulesoft.dw.xml_reader.honourMixedContentStructure")
}
```

#### Output

```Json
{
  "com.mulesoft.dw.xml_reader.honourMixedContentStructure": true
}
```
