FILTER Generator Expression is broken in add_custom_command DEPENDS context (Visual Studio 2017 Generator, CMake 3.15.1)
In the below code the generator expression in the COMMAND context will eval to "", but in the DEPENDS context will evaluate to "file.pot.cpp.txt".
cmake_minimum_required(VERSION 3.15)
project("test")
add_custom_command(OUTPUT test.stamp
COMMAND "${CMAKE_COMMAND}" -E "$<FILTER:file.pot.cpp.txt,EXCLUDE,\\.pot\\.cpp>"
DEPENDS "$<FILTER:file.pot.cpp.txt,EXCLUDE,\\.pot\\.cpp>")
add_custom_target(test_target ALL SOURCES test.stamp)