From f8d9ff23eb8d3e3286ff5cf4d5f9493532991bb7 Mon Sep 17 00:00:00 2001 From: zlg Date: Thu, 16 Jun 2016 10:15:33 -0700 Subject: The massive astyle sweep! Code style should be consistent now. All future commits will be run through astyle or they will be amended. --- ch4/4-10_getline-calc.c | 4 ---- 1 file changed, 4 deletions(-) (limited to 'ch4/4-10_getline-calc.c') diff --git a/ch4/4-10_getline-calc.c b/ch4/4-10_getline-calc.c index 499e71a..a801f0c 100644 --- a/ch4/4-10_getline-calc.c +++ b/ch4/4-10_getline-calc.c @@ -63,7 +63,6 @@ int main() { double op2; char s[MAXOP]; char ltr; - while (mygetline(buf, BUFSIZE) != 0) { bufp = 0; while ((type = getop(s)) != '\0') { @@ -188,7 +187,6 @@ double pop(void) { int getop(char s[]) { int i, c; - while ((s[0] = c = buf[bufp++]) == ' ' || c == '\t'); if (c >= 'a' && c <= 'z') { return c; @@ -210,7 +208,6 @@ int getop(char s[]) { } else { s[i] = c; } - if (isdigit(c)) { while (isdigit(s[++i] = c = buf[bufp++])); } @@ -264,7 +261,6 @@ double fetch_last(void) { int mygetline(char s[], int lim) { int c, i = 0; - while (--lim > 0 && (c = getchar()) != EOF && c != '\n') { s[i++] = c; } -- cgit v1.2.3-54-g00ecf efs/?id=45b8159cc39792ddc4e989b11036f026d49f33e7'>refslogtreecommitdiff
path: root/ch1/1-02_escape-sequences.c (unfollow)
AgeCommit message (Expand)AuthorFilesLines