aboutsummaryrefslogtreecommitdiffstats
path: root/prog
diff options
context:
space:
mode:
authorDmitry Vyukov <dvyukov@google.com>2018-05-07 17:59:06 +0200
committerDmitry Vyukov <dvyukov@google.com>2018-05-07 17:59:06 +0200
commit9e0846e8a4beebff36c72f03479a7db775b5144e (patch)
tree5be248f1b661837ea2378648676e3f0f8d5746c6 /prog
parent99c1f486598445575a3a624bf70dc6a31f60d365 (diff)
all: get rid of underscores in identifiers
Underscores are against Go coding style. Update #538
Diffstat (limited to 'prog')
-rw-r--r--prog/rand.go12
-rw-r--r--prog/types.go10
2 files changed, 11 insertions, 11 deletions
diff --git a/prog/rand.go b/prog/rand.go
index ad0ef1c7c..5489ca10d 100644
--- a/prog/rand.go
+++ b/prog/rand.go
@@ -322,7 +322,7 @@ func (r *randGen) createResource(s *state, res *ResourceType) (arg Arg, calls []
func (r *randGen) generateText(kind TextKind) []byte {
switch kind {
- case Text_arm64:
+ case TextArm64:
// Just a stub, need something better.
text := make([]byte, 50)
for i := range text {
@@ -337,7 +337,7 @@ func (r *randGen) generateText(kind TextKind) []byte {
func (r *randGen) mutateText(kind TextKind, text []byte) []byte {
switch kind {
- case Text_arm64:
+ case TextArm64:
return mutateData(r, text, 40, 60)
default:
cfg := createIfuzzConfig(kind)
@@ -365,13 +365,13 @@ func createIfuzzConfig(kind TextKind) *ifuzz.Config {
},
}
switch kind {
- case Text_x86_real:
+ case TextX86Real:
cfg.Mode = ifuzz.ModeReal16
- case Text_x86_16:
+ case TextX86bit16:
cfg.Mode = ifuzz.ModeProt16
- case Text_x86_32:
+ case TextX86bit32:
cfg.Mode = ifuzz.ModeProt32
- case Text_x86_64:
+ case TextX86bit64:
cfg.Mode = ifuzz.ModeLong64
}
return cfg
diff --git a/prog/types.go b/prog/types.go
index 74dc17d02..9b80d0576 100644
--- a/prog/types.go
+++ b/prog/types.go
@@ -252,11 +252,11 @@ const (
type TextKind int
const (
- Text_x86_real TextKind = iota
- Text_x86_16
- Text_x86_32
- Text_x86_64
- Text_arm64
+ TextX86Real TextKind = iota
+ TextX86bit16
+ TextX86bit32
+ TextX86bit64
+ TextArm64
)
type BufferType struct {