타입,type

가능한 다른 번역들: 자료형(data type), ... 형, 유형, .... (type theory와 무관한 것도 많지만 번역 참고: KmsE:type KpsE:type NdEn:type Ndict:type ... WtEn:type )

2023-11-18 페이지 길어져서 편집 불편한데, typing 분리할까? 타이핑,typing { page name due to kornorms 2023-11-18. }

type_annotation -> 현재(2024-04-10)로선 function_definition / function_annotation / type_hint / type_signature ... 과 페이지 구분 필요 없음. curr. 애너테이션,annotation


1. type과 data type - TBD...

TBD: 자료형,data_type을 여기와 분리?
https://hut.mearie.org/data-type/
WpSimple:Data_type
WpKo:자료형
WpEn:Data_type
Sub: 추상자료형 추상자료타입 추상데이터형 추상데이터타입 abstract_data_type ADT (pagename TBD)

범주론,category_theory 범주,category가 상위주제이면 여기 타입,type페이지로 하고
CS > data_structure가 상위주제이면 데이터타입 자료타입 자료형 data_type 페이지로 할까?

WtEn:type#Noun 10. 보면 data_type 과 동의어?

2. 여러 타입들

/// -type
primitive_type =,primitive_type . primitive_type
primitive_data_type =,primitive_data_type . primitive_data_type
{
primitive data type
"primitive data type"
Ggl:primitive data type

이건 PL마다 다를텐데 대개
문자열,string은 여기 포함? pl에 따라 다름?

JavaScript의 primitive data type : 7개.
https://developer.mozilla.org/en-US/docs/Glossary/Primitive
string
number
bigint
boolean
undefined
symbol
null




Boolean_data_type: // or boolean_data_type ? Srch:boolean_data_type
{
literal로는
보통 true false 를 쓰고
1 0 과 구분을 하지 않는 경우도 많고
lisp의 경우 특이하게 t nil을 쓰는 듯...?

undefined, 0(int), 0.0(float) 등의 일부 값이 false로, 나머지는 true로, 이런게 자주 쓰이는데.. 정확한 명칭 및 rationale?



자연수타입,natural_number_type =자연수타입,natural_number_type =,natural_number_type . natural_number_type
{
natural numbers type
natural number type 일단 정규화때문에 어쩔수없이 pagename은 이랬는데, .........복수형이 better? 당연히 natural language로서의 English 표현은 복수형이 자연스럽다만.




composite_type =,composite_type . composite_type
composite_data_type =,composite_data_type . composite_data_type
{



이하 동의어들

aka compound_data_type or compound_type
composite와 차이?
"a composite data type or compound data type is"[1] 에 따르면 동의어같음.


aka aggregate_type { aggregate type https://foldoc.org/aggregate type Bing:aggregate type Ggl:aggregate type "aggregate type" } 다만 이건 "may also refer to arrays, lists, etc."

aka structure
}

// (singular? 가 아닌(primitive 말고, 개수가 항상 한개)) composite/compound/aggregate 에서만 할수있는건뭐가있을지
일단생각나는 대로 나열+추가 (정확하지 않음,chk.) 틀렸으면 그냥 지우지 말고 그 rational 을 적어놓을 것.
built-in_type
builtin_type
{
WtEn:built-in_type
}


value_type
WtEn:value_type
값,value


abstract_data_type ADT
{
MKLINK abstract_type //바로아래


// TODO 위아래 둘 구분

abstract_type =,abstract_type . abstract_type
{
추상타입 ?

MKLINK abstract_data_type //바로위







문자,character
type : character_type or character_data_type
{
보통, code_point를 표현하는 수,number (esp 0을 포함한 자연수) 와 다루는 방식이 비슷한??


문자열,string
type : string_type or string_data_type
{
일반적으로 PL에서 string이라 하면 character_string (string of character) 를 뜻하고
ADT로는
.. 문자,character시퀀스,sequence 로 다루는 데 문제없게
concrete_type / data_structure 쪽으로는 i.e. 구체적 구현,implementation까지 생각하려면
.. 인덱스,index를 사용한 접근,access, slicing concatenation 등 각종 연산,operation(i.e. 문자열연산,string_operation), dynamic_allocation( static_string , string_constant , immutable_string 인 경우 무관), ....등 생각할 게 많은데





집합,set - pagename: 저건 수학의 집합론의 page로 놔두고 세트,set 셋,set 은 어떨지?
{
순서,order 없음. (unordered)


disjoint_set pagename?
or union-find.
... Google:disjoint set


키 = 값
key = value
구조 해시테이블,hash_table.



ordered_dictionary? ... { ordered dictionary Ndict:ordered dictionary Google:ordered dictionary Bing:ordered dictionary "ordered dictionary" }

}

3. type의 속성들?

크기,size - in bytes
길이,length
OOP가 있을때
parent type, etc

4. Topics

type_casting
{
Forcing a variable to behave as a type other than the one originally intended for it[2]
... Google:type casting Naver:type casting
}


// 위아래 same?


WpKo:형_변환
"type conversion, type casting, type coercion, type juggling" 이것들 같은 거??
WpEn:Type_conversion


type_variable
{
타입변수 ?
generic type variable = schematic type variable
변수,variable




type_inference
{
타입추론




type_safety
{
타입안정성 ?
타입안전 ?
타입안전성 ?

type_error 를 최소화하거나 막는

aka type_soundness (type 건전성soundness)




type_checking
{
타입체킹
타입검사
..중에 tbd.

compile time에 타입이 검사된다면 static type checking 언어.
runtime에 타입이 검사된다면 dynamic type checking 언어.


type_compatibility
{
타입호환 ?
타입호환성 ?
aka type_equivalence 타입동등 타입동등성 ?

MKLINK
자동형변환/자동형전환/coercion
QQQ weak일때는 이게 무난하고 (대신 알 수 없는(silent한) 버그가 생길 수 있고) strong일때는 이게 까다로운 것?



type_arithmetic =,type_arithmetic . type_arithmetic
{
type arithmetic
타입산술 ?

https://wiki.haskell.org/Type_arithmetic

"type arithmetic"
Ggl:type arithmetic
Up: 타입,type 산술,arithmetic
}

타입체계,type_system =타입체계,type_system =,type_system . type_system 타입체계
{
타입시스템 타입체계 .... 중 TBD. -> 타입체계 가 가장 무난한 듯
다른 번역들:
자료형 체계
형 체계
....


Sub:
nominative_type_system = name-based_type_system = nominal_type_system
{

contrast with: structural_type_system "s, where comparisons are based on the structure of the types in question and do not require explicit declarations."[3]

WtEn:nominative_type_system
= https://en.wiktionary.org/wiki/nominative_type_system
AKA: syn. name-based type system, nominal type system

WpEn:Nominal_type_system
WpKo:명목적_자료형_체계
= https://ko.wikipedia.org/wiki/명목적_자료형_체계
"명목적 또는 이름 기반 자료형 체계(nominal 혹은 nominative type system)"
}

structural_type_system
{
구조적 자료형 체계 ?

structural_type_system
}

위 둘 비교
Wiki:NominativeAndStructuralTyping
unified_type_system =,unified_type_system . unified_type_system
{

unified type system



... Google:unified.type.system
Bing:unified type system
"unified type system"
}

pure_type_system
{
classical pure type systems (CPTS)
modal pure type systems (MPTS)


type_system_design =,type_system_design . type_system_design
{
타입 시스템 설계
type system design


}


Twin:







system의 번역을 시스템 체계 ... 중에 뭐로?
시스템,system ...?
체계?
} // type system Ggl:type system

type_scheme =,type_scheme . type_scheme
{
type scheme





type_synonym =,type_synonym . type_synonym
{
type synonym


C언어에선 typedef.


type_annotation =,type_annotation . type_annotation
{
type annotation
'type hint'?
syn? chk. type_hint

애너테이션,annotation

명시적으로: manifest_typing ... http://wiki.c2.com/?ManifestTyping
암시적으로: implicit_typing ... http://wiki.c2.com/?ImplicitTyping




type_signature (= type_annotation (wpen)) =,type_signature . type_signature
{
type signature


Twin





type_class =,type_class . type_class | =,typeclass typeclass
{
type class
AKA typeclass (via WtEn:typeclass )

https://en.wiktionary.org/wiki/type_class
"(programming) A type system construct that supports ad hoc polymorphism (independent of the type_hierarchy), first pioneered in Haskell."(2024-01-13)

WpEn:Type_class
= https://en.wikipedia.org/wiki/Type_class


} // type class ... Google:type.class Naver:type.class


type_family =,type_family . type_family
{
type family

타입족 ?



} // type family ... Ndict:type family 보면 활자에서도 쓰임. / Naver:type family / Ggl:type family

type_constructor =,type_constructor . type_constructor
{
type constructor







subtype
{
서브타입



... Google:subtype Naver:subtype
}
subtyping =,subtyping =,subtyping . subtyping
{
curr see also 다형성,polymorphism



supertype =,supertype =,supertype . supertype
{
WtEn:supertype
= https://en.wiktionary.org/wiki/supertype "The data type represented by a superclass."


... Google:supertype
}

subtype and supertype
{


recursive_type =,recursive_type . recursive_type
recursive_data_type
{
recursive type
recursive data type

재귀,recursion
바로아래 inductive_type과 비교.




inductive_type =,inductive_type . inductive_type
inductive_data_type
{
귀납,induction? - VG 귀납,induction

바로위 recursive_type과 비교.








refinement_type =,refinement_type . refinement_type
{
"refinement type"


....
Bing:refinement type
Ggl:refinement type
"refinement type"
}

dependent_type =,dependent_type . dependent_type
{
타입의 정의가 값,value에 달린

dependent type





WpEn:Return_type
= https://en.wikipedia.org/wiki/Return_type
"the return type (or result_type) defines and constrains the data type of the value returned from a subroutine or method."

... Google:Return.type
}


/// -typing

typing =,typing =,typing . typing
{
타이핑 ?? 번역은? NdEn:typing Ndict:typing Ggl:typing 뜻 Ggl:typing 번역


static_typing =,static_typing =,static_typing . static_typing
{
Wiki:StaticTyping = http://wiki.c2.com/?StaticTyping






// 아래 둘은 type_strength ...라는 개념으로 분류가능. https://rosettacode.org/wiki/Type_strength 에 따르면 PL들은 strongly typed / weakly typed / untyped 셋으로 구분.
// 아래 둘 비교. https://wiki.python.org/moin/StrongVsWeakTyping

weak_typing =,weak_typing =,weak_typing . weak_typing
{
weak typing

WtEn:weak_typing = https://en.wiktionary.org/wiki/weak_typing
"A system that does not place any restriction on the interactions between objects of different data types." (2023-11-18)

Wiki:WeakTyping = http://wiki.c2.com/?WeakTyping

...
"weak typing"
Google:weak.typing Naver:weak.typing
aka loose typing = loose_typing
}

strong_typing =,strong_typing =,strong_typing . strong_typing
{
strong typing

WtEn:strong_typing = https://en.wiktionary.org/wiki/strong_typing
"A system that places any of various kinds of restriction on the interactions between objects of different data types." (2023-11-18)

Wiki:StrongTyping = http://wiki.c2.com/?StrongTyping


...
"strong typing"
Google:strong.typing Naver:strong.typing
}



weak/strong, static/dynamic을 비교한 사분면은 typing_quadrant
{
https://wiki.c2.com/?TypingQuadrant


Hindley-Milner
{
Hindley-Milner type system




... Google:Hindley-Milner Naver:Hindley-Milner
"Hindley-Milner type system"
}

5. function to get type

6. QQQ

C의 void는 type인가? type이 없다는 것을 명시하는 specifier인가?

7. (type theory의 type 말고)

file_format file_type 혹은 data encoding/decoding 그쪽에 가까운

7.2. media type / MIME type

media_type MIME_type
Ggl:media type mime type
rel. MIME { Srch:MIME Zeta:MIME }

8. MISC

C언어(+ 거기서 유래한 C++) 표준 types 이름을 _t suffix 로 하는 관례가 있다. 그냥 int long ...을 쓰는 것보다 확실히 명확함.
  • size_t
  • ssize_t
  • ptrdiff_t
  • 그러고보니 유닉스도.
  • pid_t
  • uint8_t ....이건 size(비트,bit 수)가 확실히 명확함. 이게 너무 늦게 C 표준에 추가된 듯 싶다, 요새 언어는 이걸 기본 탑재하고 나오는 추세. Rust 등


Delphi인가 Pascal인가 Object_Pascal인가 거기선 T suffix 붙이는 것을 보았고

MFC에서 클래스는 C prefix 붙이고

(hungarian notation같은) identifier name에 뭔가를 수식하는 관습을 최대한 버리려고 노력한(? 내생각) C#이지만 인터페이스,interface를 에서는 I prefix 로 시작하는 관습이... chk

갈수록 prefix/suffix notation/convention같은것 배제하고 클래스/타입 이름은 대문자로 시작하는, 인스턴스/변수 이름은 소문자로 시작하는 것으로 구분하는게 그냥 대세인듯(보기 편하니까? readability)

이상 conventions는 sigil로 명확히 구분 가능한 PL에서는 의미가 없는 듯 싶고

아무튼 이런거 나중에 모으거나 정리하거나 삭제하거나.

10. .NET System.Type class

11. Misc, Etc

type은 활자를 뜻하기도 함. 특히 앞에 movable이 붙으면 의미가 확실해짐. 활자,movable_type Srch:활자,





----