diff options
author | Christopher Koch <chrisko@google.com> | 2018-12-29 11:26:27 -0800 |
---|---|---|
committer | insomniac <insomniacslk@users.noreply.github.com> | 2019-01-14 23:19:04 +0000 |
commit | 75d26a6410980df90d3a9d224956cfe5ed35a07f (patch) | |
tree | a98dbe3358f013b3146b26ffca3225b70cc194fd /iana | |
parent | 158ad8e79b2e644da7dfbfceb9191e6587ede81e (diff) |
Rename iana.ArchType to iana.Arch.
Diffstat (limited to 'iana')
-rw-r--r-- | iana/archtype.go | 39 |
1 files changed, 19 insertions, 20 deletions
diff --git a/iana/archtype.go b/iana/archtype.go index ca21490..510c6fc 100644 --- a/iana/archtype.go +++ b/iana/archtype.go @@ -1,24 +1,24 @@ package iana -//ArchType encodes an architecture type in an uint16 -type ArchType uint16 +// Arch encodes an architecture type per RFC 4578, Section 2.1. +type Arch uint16 -// see rfc4578 +// See RFC 4578. const ( - INTEL_X86PC ArchType = 0 - NEC_PC98 ArchType = 1 - EFI_ITANIUM ArchType = 2 - DEC_ALPHA ArchType = 3 - ARC_X86 ArchType = 4 - INTEL_LEAN_CLIENT ArchType = 5 - EFI_IA32 ArchType = 6 - EFI_BC ArchType = 7 - EFI_XSCALE ArchType = 8 - EFI_X86_64 ArchType = 9 + INTEL_X86PC Arch = 0 + NEC_PC98 Arch = 1 + EFI_ITANIUM Arch = 2 + DEC_ALPHA Arch = 3 + ARC_X86 Arch = 4 + INTEL_LEAN_CLIENT Arch = 5 + EFI_IA32 Arch = 6 + EFI_BC Arch = 7 + EFI_XSCALE Arch = 8 + EFI_X86_64 Arch = 9 ) -// ArchTypeToStringMap maps an ArchType to a mnemonic name -var ArchTypeToStringMap = map[ArchType]string{ +// archTypeToStringMap maps an Arch to a mnemonic name +var archTypeToStringMap = map[Arch]string{ INTEL_X86PC: "Intel x86PC", NEC_PC98: "NEC/PC98", EFI_ITANIUM: "EFI Itanium", @@ -31,11 +31,10 @@ var ArchTypeToStringMap = map[ArchType]string{ EFI_X86_64: "EFI x86-64", } - -// String returns a mnemonic name for a given architecture type -func (a ArchType) String() string { - if at := ArchTypeToStringMap[a]; at != "" { +// String returns a mnemonic name for a given architecture type. +func (a Arch) String() string { + if at := archTypeToStringMap[a]; at != "" { return at } - return "Unknown" + return "unknown" } |