| 1 |
(* Copyright (C) 2015-2025 Free Software Foundation, Inc. *) |
| 2 |
(* This file is part of GNU Modula-2. |
| 3 |
|
| 4 |
GNU Modula-2 is free software; you can redistribute it and/or modify it under |
| 5 |
the terms of the GNU General Public License as published by the Free |
| 6 |
Software Foundation; either version 3, or (at your option) any later |
| 7 |
version. |
| 8 |
|
| 9 |
GNU Modula-2 is distributed in the hope that it will be useful, but WITHOUT ANY |
| 10 |
WARRANTY; without even the implied warranty of MERCHANTABILITY or |
| 11 |
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
| 12 |
for more details. |
| 13 |
|
| 14 |
You should have received a copy of the GNU General Public License |
| 15 |
along with GCC; see the file COPYING3. If not see |
| 16 |
<http://www.gnu.org/licenses/>. *) |
| 17 |
|
| 18 |
IMPLEMENTATION MODULE mcQuiet ; |
| 19 |
|
| 20 |
FROM mcOptions IMPORT getQuiet ; |
| 21 |
FROM mcPrintf IMPORT printf0, printf1, printf2, printf3, printf4 ; |
| 22 |
|
| 23 |
|
| 24 |
PROCEDURE qprintf0 (a: ARRAY OF CHAR) ; |
| 25 |
BEGIN |
| 26 |
IF NOT getQuiet () |
| 27 |
THEN |
| 28 |
printf0 (a) |
| 29 |
END |
| 30 |
END qprintf0 ; |
| 31 |
|
| 32 |
|
| 33 |
PROCEDURE qprintf1 (a: ARRAY OF CHAR; w: ARRAY OF BYTE) ; |
| 34 |
BEGIN |
| 35 |
IF NOT getQuiet () |
| 36 |
THEN |
| 37 |
printf1 (a, w) |
| 38 |
END |
| 39 |
END qprintf1 ; |
| 40 |
|
| 41 |
|
| 42 |
PROCEDURE qprintf2 (a: ARRAY OF CHAR; w1, w2: ARRAY OF BYTE) ; |
| 43 |
BEGIN |
| 44 |
IF NOT getQuiet () |
| 45 |
THEN |
| 46 |
printf2 (a, w1, w2) |
| 47 |
END |
| 48 |
END qprintf2 ; |
| 49 |
|
| 50 |
|
| 51 |
PROCEDURE qprintf3 (a: ARRAY OF CHAR; w1, w2, w3: ARRAY OF BYTE) ; |
| 52 |
BEGIN |
| 53 |
IF NOT getQuiet () |
| 54 |
THEN |
| 55 |
printf3 (a, w1, w2, w3) |
| 56 |
END |
| 57 |
END qprintf3 ; |
| 58 |
|
| 59 |
|
| 60 |
PROCEDURE qprintf4 (a: ARRAY OF CHAR; w1, w2, w3, w4: ARRAY OF BYTE) ; |
| 61 |
BEGIN |
| 62 |
IF NOT getQuiet () |
| 63 |
THEN |
| 64 |
printf4 (a, w1, w2, w3, w4) |
| 65 |
END |
| 66 |
END qprintf4 ; |
| 67 |
|
| 68 |
|
| 69 |
END mcQuiet. |