summaryrefslogtreecommitdiffstatsci
path: root/src/caskbench.cpp
diff options
context:
space:
mode:
authorBryce Harrington <b.harrington@samsung.com>2014-05-05 22:59:41 -0700
committerBryce Harrington <b.harrington@samsung.com>2014-05-06 00:01:40 -0700
commitc99e43124f3f9ff954acdb0de091b36d3ed91f26 (patch)
tree8bb1f0c629877df758308843726dfedb023c0abe /src/caskbench.cpp
parent9b6206001d2a05fefa1e42662b0b8db99e103a33 (diff)
Rename Shapes enum to shape_type_t and fix enum names
We already have a 'shapes' data structure, so to avoid confusion don't name our shape type enums 'Shapes'. Instead, name it shape_type_t, which is more consistent with the code style of other enums in the codebase. Also, rename Circle / Triangle / etc. to CB_SHAPE_CIRCLE / CB_SHAPE_TRIANGLE / etc. The former could be confused as class names; the latter are less likely to get confused this way, and follow the style of other enums in the codebase.
Diffstat (limited to 'src/caskbench.cpp')
-rw-r--r--src/caskbench.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/caskbench.cpp b/src/caskbench.cpp
index 81c4a07..6a05f5c 100644
--- a/src/caskbench.cpp
+++ b/src/caskbench.cpp
@@ -503,27 +503,27 @@ result_init(caskbench_result_t *result, const char* name)
}
int
-convertToShapeID(const char* shapeName)
+convertToShapeID(const char* shape_name)
{
int i =0;
- if (shapeName == NULL)
+ if (shape_name == NULL)
return 0;
while (gShapes[i] != NULL) {
- if (strcmp(gShapes[i], shapeName) == 0)
+ if (strcmp(gShapes[i], shape_name) == 0)
return i + 1;
i++;
}
}
-fillType
-convertToFillType(const char *fill_type)
+fill_type_t
+convertToFillType(const char *fill_name)
{
int i =0;
- if (fill_type == NULL)
- return (fillType) 0;
+ if (fill_name == NULL)
+ return (fill_type_t) 0;
while (gFillTypes[i] != NULL) {
- if (strcmp(gFillTypes[i], fill_type) == 0)
- return (fillType) i ;
+ if (strcmp(gFillTypes[i], fill_name) == 0)
+ return (fill_type_t) i ;
i++;
}
}