on Wed Jun 28 2017, Ben Cohen wrote:
> Hi swift-evolution,
>
> Below is a short pitch for some performance improvements to be made to String
> to accommodate
> Substrings.
>
> As outlined in SE-0163, the more general question of implicit conversion from
> Substring
Ughh, my bad, let me withdraw this idea:
func saveAndRestore(_ variable: inout T, _ tmpVal: T, body: ()
-> R) -> R {
let savedVal = variable
variable = tmpVal
defer { variable = savedVal }
return body()
}
var contextVal: Int = 0saveAndRestore(, 1) {
print(contextVal)
}
2017-07-03 11:23 GMT+09:00 rintaro ishizaki via swift-evolution <
swift-evolution@swift.org>:
>
>
> 2017-06-28 21:33 GMT+09:00 Dimitri Racordon via swift-evolution <
> swift-evolution@swift.org>:
>
>> Hello community!
>>
>> I’d like to pitch an idea for a user-friendly way for functions to pull
Hi Karl,
It was pointed out to me that I never answered this thoughtful post of
yours...
on Mon Jun 26 2017, Karl Wagner wrote:
>> On 23. Jun 2017, at 02:59, Kevin Ballard via swift-evolution
>> wrote:
>>
>>
2017-06-28 21:33 GMT+09:00 Dimitri Racordon via swift-evolution <
swift-evolution@swift.org>:
> Hello community!
>
> I’d like to pitch an idea for a user-friendly way for functions to pull
> values from an arbitrary environment. Let me introduce the concept with a
> motivational example before I
A full-fledged introspection system should provide this information, which I
suppose could be useful for creating proxies through code generation or dynamic
Objective-C like features, should they ever be added to the language. Would
that be sufficient for your needs? It is not clear to me what
> On Jul 1, 2017, at 2:07 AM, Brent Royal-Gordon wrote:
>
>> On Jun 30, 2017, at 6:17 PM, Daryle Walker via swift-evolution
>> > wrote:
>>
>> Given a type MyType, how can I get a type-alias to the type’s
> On Jun 28, 2017, at 5:33 AM, Dimitri Racordon via swift-evolution
> wrote:
>
> Using our contextual variables, one could rewrite our motivational example as
> follows:
>
> class Interpreter: Visitor {
> func visit(_ node: BinExpr) {
> let lhs, rhs :
I think I got most of this, but it’s hard to completely figure out because the
information is scattered across the grammar.
So, I’m coming up with a statement to copy over a member from one type to
another:
publish MEMBER-FROM-OTHER-TYPE
and I’m trying to encapsulate this into a grammar. This
> let last = array.last ?? fatalError(“array must not be empty”)
I prefer, the above, explicit version.
-g.
___
swift-evolution mailing list
swift-evolution@swift.org
https://lists.swift.org/mailman/listinfo/swift-evolution
10 matches
Mail list logo