swift的类型描述符
类型 swift 描述符
2023-09-11 14:18:44 时间
Metatype Types
A concrete or existential metatype in SIL must describe its representation. This can be:
- @thin, meaning that it requires no storage and thus necessarily represents an exact type (only allowed for concrete metatypes);
- @thick, meaning that it stores a reference to a type or (if a concrete class) a subclass of that type; or
- @objc, meaning that it stores a reference to a class type (or a subclass thereof) using an Objective-C class object representation rather than the native Swift type-object representation.
用于类型和函数类型的描述
https://github.com/apple/swift/blob/master/docs/SIL.rst#metatype-types
%2 = function_ref @ProtocolCase.NormalStruct.init() -> ProtocolCase.NormalStruct : $@convention(method) (@thin NormalStruct.Type) -> NormalStruct // user: %3
相关文章
- Delphi 解决StrToDateTime()不是有效日期类型的问题
- 编写高质量代码改善C#程序的157个建议[为类型输出格式化字符串、实现浅拷贝和深拷贝、用dynamic来优化反射]
- js的7种类型
- java 11 局部变量类型推断
- golang的指针类型,引用类型, 传值解惑
- Dart基础-变量与类型
- 《从零开始学Swift》学习笔记(Day 27)——可选类型
- 判断数字类型
- opencv中Mat与IplImage,CVMat类型之间转换
- 怎么判断当前的os类型,手机类型
- 一个简单的例子理解Kubernetes的三种IP地址类型
- 类型参数的约束(C# 编程指南)
- 解决date类型数据后面带0.000+00的问题
- 关于面向对象设计中类的方法是否应该使用boolean类型的参数
- ios swift 可选值(类型)的本质 Optional
- iOS swift打印方法名,类名和文件地址(打印的时候显示时间,类型,在第几行)
- MIME类型
- swift的struct本节描述结构的类型