swift
339932ea - [codable] When generated encode for a property, distinguish in between static/instance properties.

Commit
7 years ago
[codable] When generated encode for a property, distinguish in between static/instance properties. Previously, we just took the first match so: 1. We would try to emit a metatype lookup of the property but had prepared an instance lookup. 2. Could get the wrong type if the static/instance property had different types. rdar://39669212 (cherry picked from commit 3d990e98d214b1ef34652b120cb449cf9132fba3)
Author
Committer
Parents
  • lib/Sema
    • File
      DerivedConformanceCodable.cpp
  • test
    • SILGen/codable
      • File
        struct_codable_member_type_lookup.swift
    • decl/protocol/special/coding
      • File
        struct_codable_member_type_lookup.swift