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

Xcode has special behavior for disallowed languages #1085

Closed
Gaztin opened this issue May 12, 2018 · 0 comments · Fixed by #1086
Closed

Xcode has special behavior for disallowed languages #1085

Gaztin opened this issue May 12, 2018 · 0 comments · Fixed by #1086

Comments

@Gaztin
Copy link
Contributor

Gaztin commented May 12, 2018

Xcode seems to have special behavior for reinterpreting a file as either objective-c or objective-c++ (referenced below)

function xcode.getfiletype(node, cfg)
if node.configs then
local filecfg = fileconfig.getconfig(node, cfg)
if filecfg then
if filecfg.language == "ObjC" then
return "sourcecode.c.objc"
elseif filecfg.language == "ObjCpp" then
return "sourcecode.cpp.objcpp"
end
end
end

..but neither of them are allowed languages for file configs.

filter {"files:Foo.cpp"}
    language "ObjCpp"

Above code will, in fact, throw an error (unless I explicitly call api.addAllowed("language", "ObjCpp") ,in which case it works as intended)

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 a pull request may close this issue.

1 participant