changeset 352:582f538160d8

...
author anatofuz <anatofuz@cr.ie.u-ryukyu.ac.jp>
date Mon, 02 Mar 2020 18:29:05 +0900
parents 1fb6c09db515
children c958c355f805
files src/impl/ConsoleIO.cbc src/impl/ConsoleIO.h
diffstat 2 files changed, 9 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/src/impl/ConsoleIO.cbc	Mon Mar 02 18:16:50 2020 +0900
+++ b/src/impl/ConsoleIO.cbc	Mon Mar 02 18:29:05 2020 +0900
@@ -34,7 +34,7 @@
     goto io->consoleread(__code next(...));
 }
 
-__code consoleread(struct ConsoleIO* IO, struct inode* ip, char* dst, int n, __code next(...)) {
+__code consoleread(struct ConsoleIO* io, struct inode* ip, char* dst, int n, __code next(...)) {
     uint target;
 
     iunlock(ip);
@@ -43,12 +43,12 @@
     acquire(&input.lock);
 
     if (n > 0) {
-      goto IO->consoleread2(IO, n, ip, target, dst, ip, next);
+      goto io->consoleread2(io, n, ip, target, dst, ip, next);
     }
-    goto IO->consoleread1(IO, n, target, dst, ip, next);
+    goto io->consoleread1(io, n, target, dst, ip, next);
 }
 
-__code consoleread1(struct ConsoleIO* IO, int n, int target, char* dst, struct inode* ip, __code next(...)) {
+__code consoleread1(struct ConsoleIO* io, int n, int target, char* dst, struct inode* ip, __code next(...)) {
     int c = input.buf[input.r++ % INPUT_BUF];
 
     if (c == C('D')) {  // EOF
@@ -79,7 +79,7 @@
     goto next(target - n);
 }
 
-__code consoleread2(struct ConsoleIO* IO, struct inode*  ip, __code next(...)) {
+__code consoleread2(struct ConsoleIO* io, struct inode*  ip, __code next(...)) {
     if (input.r == input.w) { // input is global variable
         if (proc->killed) {
             release(&input.lock);
@@ -88,7 +88,7 @@
         }
        goto cbc_sleep(&input.r, &input.lock, cbc_consoleread2);
     }
-    goto IO->consoleread1();
+    goto io->consoleread1();
 }
 
 
--- a/src/impl/ConsoleIO.h	Mon Mar 02 18:16:50 2020 +0900
+++ b/src/impl/ConsoleIO.h	Mon Mar 02 18:29:05 2020 +0900
@@ -1,6 +1,6 @@
 typedef struct ConsoleIO <Type, Isa> impl IO {
-  __code consoleread(Type* IO, struct inode* ip, char* dst, int n, __code next(...));
-  __code consoleread1(Type* IO, int n, int target, char* dst, struct inode* ip, __code next(...));
-  __code consoleread2(Type* IO, struct inode*  ip, __code next(...));
+  __code consoleread(Type* io, struct inode* ip, char* dst, int n, __code next(...));
+  __code consoleread1(Type* io, int n, int target, char* dst, struct inode* ip, __code next(...));
+  __code consoleread2(Type* io, struct inode*  ip, __code next(...));
   __code next(....);
 } ConsoleIO;