欢迎光临散文网 会员登陆 & 注册

C++笔记 | 常见数据在typeid(param).name()里的表示

2022-08-01 22:48 作者:LogByMax  | 我要投稿

(认知有限,如有不妥,还望告知,欢迎讨论)

常见数据在typeid(param).name()里的表示及其所占字节数。

输出结果:

 *** int *** 

d1 in typeid is i.  -  the size of this data type is 4 bytes.  -  

d2 in typeid is Pi.  -  the size of this data type is 8 bytes.  -  

d3 in typeid is i.  -  the size of this data type is 4 bytes.  -  

d4 in typeid is i.  -  the size of this data type is 4 bytes.  -  

d5 in typeid is PKi.  -  the size of this data type is 8 bytes.  -  

d6 in typeid is i.  -  the size of this data type is 4 bytes.  -  

d7 in typeid is j.  -  the size of this data type is 4 bytes.  -  

d8 in typeid is Pj.  -  the size of this data type is 8 bytes.  -  

d9 in typeid is j.  -  the size of this data type is 4 bytes.  -  

d10 in typeid is PKj.  -  the size of this data type is 8 bytes.  -  

 *** *** *** 


 *** short int *** 

d11 in typeid is s.  -  the size of this data type is 2 bytes.  -  

d12 in typeid is Ps.  -  the size of this data type is 8 bytes.  -  

d13 in typeid is s.  -  the size of this data type is 2 bytes.  -  

d14 in typeid is s.  -  the size of this data type is 2 bytes.  -  

d15 in typeid is PKs.  -  the size of this data type is 8 bytes.  -  

d16 in typeid is s.  -  the size of this data type is 2 bytes.  -  

d17 in typeid is t.  -  the size of this data type is 2 bytes.  -  

d18 in typeid is Pt.  -  the size of this data type is 8 bytes.  -  

d19 in typeid is t.  -  the size of this data type is 2 bytes.  -  

d20 in typeid is PKt.  -  the size of this data type is 8 bytes.  -  

 *** *** *** 


 *** long int *** 

d21 in typeid is l.  -  the size of this data type is 8 bytes.  -  

d22 in typeid is Pl.  -  the size of this data type is 8 bytes.  -  

d23 in typeid is l.  -  the size of this data type is 8 bytes.  -  

d24 in typeid is l.  -  the size of this data type is 8 bytes.  -  

d25 in typeid is PKl.  -  the size of this data type is 8 bytes.  -  

d26 in typeid is l.  -  the size of this data type is 8 bytes.  -  

d27 in typeid is m.  -  the size of this data type is 8 bytes.  -  

d28 in typeid is Pm.  -  the size of this data type is 8 bytes.  -  

d29 in typeid is m.  -  the size of this data type is 8 bytes.  -  

d30 in typeid is PKm.  -  the size of this data type is 8 bytes.  -  

 *** *** *** 


 *** float *** 

d31 in typeid is f.  -  the size of this data type is 4 bytes.  -  

d32 in typeid is Pf.  -  the size of this data type is 8 bytes.  -  

d33 in typeid is f.  -  the size of this data type is 4 bytes.  -  

d34 in typeid is f.  -  the size of this data type is 4 bytes.  -  

d35 in typeid is PKf.  -  the size of this data type is 8 bytes.  -  

d36 in typeid is f.  -  the size of this data type is 4 bytes.  -  

 *** *** *** 


 *** double *** 

d41 in typeid is d.  -  the size of this data type is 8 bytes.  -  

d42 in typeid is Pd.  -  the size of this data type is 8 bytes.  -  

d43 in typeid is d.  -  the size of this data type is 8 bytes.  -  

d44 in typeid is d.  -  the size of this data type is 8 bytes.  -  

d45 in typeid is PKd.  -  the size of this data type is 8 bytes.  -  

d46 in typeid is d.  -  the size of this data type is 8 bytes.  -  

 *** *** *** 


 *** long double *** 

d51 in typeid is e.  -  the size of this data type is 16 bytes.  -  

d52 in typeid is Pe.  -  the size of this data type is 8 bytes.  -  

d53 in typeid is e.  -  the size of this data type is 16 bytes.  -  

d54 in typeid is e.  -  the size of this data type is 16 bytes.  -  

d55 in typeid is PKe.  -  the size of this data type is 8 bytes.  -  

d56 in typeid is e.  -  the size of this data type is 16 bytes.  -  

 *** *** *** 


 *** char *** 

d61 in typeid is c.  -  the size of this data type is 1 bytes.  -  

d62 in typeid is Pc.  -  the size of this data type is 8 bytes.  -  

d63 in typeid is c.  -  the size of this data type is 1 bytes.  -  

d64 in typeid is c.  -  the size of this data type is 1 bytes.  -  

d65 in typeid is PKc.  -  the size of this data type is 8 bytes.  -  

d66 in typeid is c.  -  the size of this data type is 1 bytes.  -  

d67 in typeid is h.  -  the size of this data type is 1 bytes.  -  

d68 in typeid is Ph.  -  the size of this data type is 8 bytes.  -  

d69 in typeid is h.  -  the size of this data type is 1 bytes.  -  

d70 in typeid is PKh.  -  the size of this data type is 8 bytes.  -  

 *** *** *** 


 *** wchar_t *** 

d70 in typeid is PKh.  -  the size of this data type is 8 bytes.  -  

d71 in typeid is w.  -  the size of this data type is 4 bytes.  -  

d72 in typeid is Pw.  -  the size of this data type is 8 bytes.  -  

d73 in typeid is w.  -  the size of this data type is 4 bytes.  -  

d74 in typeid is w.  -  the size of this data type is 4 bytes.  -  

d75 in typeid is PKw.  -  the size of this data type is 8 bytes.  -  

d76 in typeid is w.  -  the size of this data type is 4 bytes.  -  

 *** *** *** 


 *** bool *** 

d81 in typeid is b.  -  the size of this data type is 1 bytes.  -  

 *** *** *** 


=END=

C++笔记 | 常见数据在typeid(param).name()里的表示的评论 (共 条)

分享到微博请遵守国家法律