Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: support iterating list containing generator expressions that have semicolons #250

Merged
merged 2 commits into from
Feb 28, 2024

Conversation

FeignClaims
Copy link
Contributor

Add a function convert_genex_semicolons to convert semicolons inside generator expressions into $<SEMICOLON>. After this function, the list contains generator expressions can be properly iterated.

set(dirs "$<$<CONFIG:Debug>:dir1;dir2>" "$<$<CONFIG:Release>:dir3;dir4>")

convert_genex_semicolons("${dirs}" dirs)
# now dirs is "$<$<CONFIG:Debug>:dir1$<SEMICOLON>dir2>;$<$<CONFIG:Release>:dir3$<SEMICOLON>dir4>"

foreach(dir IN LISTS dirs)
  # element 0: "$<$<CONFIG:Debug>:dir1$<SEMICOLON>dir2>"
  # element 1: "$<$<CONFIG:Release>:dir3$<SEMICOLON>dir4>"
endforeach()

Close #205

@aminya aminya merged commit ea62d10 into aminya:main Feb 28, 2024
19 checks passed
@FeignClaims FeignClaims deleted the fix/foreach_genex branch March 1, 2024 00:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

target_link_system_directories dosen't support generator expressions that have semicolons
2 participants