You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Clang has the Internals manual, and swiftc should have something similar. Particularly, I'm very interested in the following case being documented. Once it is, I feel like people would be better able to understand the compiler and add to it.
Let's say I have a type called SuperInt that has some cool integer operations that would be applicable and useful to everyone writing Swift. It's a given that this makes sense to be in the Swift language, and people are going to be using it so often that it makes sense to create a new literal syntax for this type. I'd like users to be able to instantiate a SuperInt with the following:
letsuperIntExample = %^100^%
Crazy syntax for a crazy example, but I wanted to make sure it's not something that's already in Swift. In this example, my SuperInt would be instantiated with a value of 100.
I'd like to know the parts of the Swift compiler I would need to understand and change to implement this new type with its new syntax.
The text was updated successfully, but these errors were encountered:
Additional Detail from JIRA
md5: 1d62b4814b55823dfda00bacb8aca661
Issue Description:
Clang has the Internals manual, and swiftc should have something similar. Particularly, I'm very interested in the following case being documented. Once it is, I feel like people would be better able to understand the compiler and add to it.
Let's say I have a type called SuperInt that has some cool integer operations that would be applicable and useful to everyone writing Swift. It's a given that this makes sense to be in the Swift language, and people are going to be using it so often that it makes sense to create a new literal syntax for this type. I'd like users to be able to instantiate a SuperInt with the following:
Crazy syntax for a crazy example, but I wanted to make sure it's not something that's already in Swift. In this example, my SuperInt would be instantiated with a value of 100.
I'd like to know the parts of the Swift compiler I would need to understand and change to implement this new type with its new syntax.
The text was updated successfully, but these errors were encountered: