Skip to content

Changes related to SE-0028 #255

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

Merged
merged 1 commit into from
Feb 12, 2016
Merged

Changes related to SE-0028 #255

merged 1 commit into from
Feb 12, 2016

Conversation

Austinate
Copy link
Contributor

Replaces old identifiers with new ones

@Austinate
Copy link
Contributor Author

One thing i'm not sure about is __PRETTY_FUNCTION__ which actually is define for __FUNCTION__but is not covered in SE-0028
Should we rename it too or left same for compatibility?

@lattner
Copy link
Contributor

lattner commented Feb 5, 2016

The changes to the .c and .h files seem very wrong to me, they won't build.

@Austinate
Copy link
Contributor Author

My bad, will fix

@Austinate
Copy link
Contributor Author

@lattner reverter those changes, sorry for that ¯_(ツ)_/¯

@phausler
Copy link
Contributor

phausler commented Feb 5, 2016

what corresponding commit for the compiler is this attached to?

@Austinate
Copy link
Contributor Author

This one

@phausler
Copy link
Contributor

phausler commented Feb 5, 2016

thanks

@@ -1039,8 +1039,8 @@ func checkHasPrefixHasSuffix(lhs: String, _ rhs: String, _ stack: [UInt]) -> Int
}

var failures = 0
failures += testFailure(expectHasPrefix, lhs.hasPrefix(rhs), stack + [__LINE__])
failures += testFailure(expectHasSuffix, lhs.hasSuffix(rhs), stack + [__LINE__])
failures += testFailure(expectHasPrefix, lhs.hasPrefix(rhs), stack + [#line])
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't compile for me.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems [#line] doesn't compile but [ #line] does. Intentional as part of SE-0028?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This includes keeping __FUNCTION__, and making #line have the dual behavior of being a directive when it is the first token on a line, but an expression otherwise.

From SE-0028
So if #line is taken as expression it looks like it should work. Or i'm missing something.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm - @lattner ?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was fixed in a follow on patch. Just put a space between the [ and # if you don't have a build with the fix yet.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@phausler
Copy link
Contributor

@swift-ci Please test

phausler added a commit that referenced this pull request Feb 12, 2016
Changes related to SE-0028
@phausler phausler merged commit 76b5af2 into swiftlang:master Feb 12, 2016
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.

4 participants