[swift-dev] Location of "indirect" declaration modifier

Marc Knaup marc at knaup.koeln
Fri Dec 11 05:06:47 CST 2015


Hey guys,

I'm working on a proposal and the question arose why the declaration
modifier indirect can only be specified for the whole enum case and the
whole enum but not for the actual parameter which is indirect.

I.e. is there any technical reason which would prevent something like the
following?


   1. enum ArithmeticExpression {
   2. case Number(Int)
   3. case Addition(indirect ArithmeticExpression, indirect
   ArithmeticExpression)
   4. case Multiplication(indirect ArithmeticExpression, indirect
   ArithmeticExpression)
   5. }


Also is there any technical reason which would prevent indirect from being
used for structs?

Thanks,
  Marc
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.swift.org/pipermail/swift-dev/attachments/20151211/48d824c9/attachment.html>


More information about the swift-dev mailing list