[swift-evolution] [Proposal] Revamp the playground quicklook APIs
Chris Lattner
clattner at nondot.org
Wed Jan 10 12:02:54 CST 2018
> On Jan 9, 2018, at 11:30 PM, Saagar Jha <saagar at saagarjha.com> wrote:
>>
>> In short, can we change playgroundRepresentation to return Any instead of Any?. Among other things, doing so could ease the case of playground formatting Optional itself, which should presumably get a conditional conformance to this. :-)
>
> I believe the rationale behind this was to provide a way to “opt-out” of a customized representation, although now that I think about it, what exactly does the default mean? In particular, what happens in this case?
If you want a type to display as nothing (e.g. to avoid the perf impact of formatting it) just make the playground representation be an empty string or something.
-Chris
More information about the swift-evolution
mailing list