# Documenation issue on policy CMP0127

**URL:** https://discourse.cmake.org/t/documenation-issue-on-policy-cmp0127/14164
**Category:** Usage
**Created:** [May 26, 2025, 5:44pm UTC](https://discourse.cmake.org/t/documenation-issue-on-policy-cmp0127/14164 "2025-05-26T17:44:13Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![czertyaka](https://discourse.cmake.org/user_avatar/discourse.cmake.org/czertyaka/32/5584_2.png) [@czertyaka](https://discourse.cmake.org/u/czertyaka)
#### Post date: [May 26, 2025, 5:44pm UTC](https://discourse.cmake.org/t/documenation-issue-on-policy-cmp0127/14164/1 "2025-05-26T17:44:13Z")

</div>

Hello!

I am confused with description of CMP0127. It says that:

> requires expressions like:  
> `"FOO MATCHES (UPPER|lower)"`  
> to be re-written as:  
> `"FOO MATCHES \"(UPPER|lower)\""`

I’ve written CMakeLists.txt like this:

```auto
cmake_minimum_required(VERSION 3.10)
project(dependent_option)

include(CMakeDependentOption)

option(FOO "" "")
cmake_dependent_option(BAR "" "" "FOO MATCHES \"(UPPER|lower)\"" OFF)

```

But it still gives me warning:

```auto
$ cmake -B build
CMake Warning (dev) at /usr/share/cmake/Modules/CMakeDependentOption.cmake:89 (message):
  Policy CMP0127 is not set: cmake_dependent_option() supports full Condition
  Syntax. Run "cmake --help-policy CMP0127" for policy details. Use the
  cmake_policy command to set the policy and suppress this warning.
Call Stack (most recent call first):
  CMakeLists.txt:7 (cmake_dependent_option)
This warning is for project developers. Use -Wno-dev to suppress it.

```
