Skip to content

Commit

Permalink
fix printMessage to print to stdError
Browse files Browse the repository at this point in the history
  • Loading branch information
mahrud committed Dec 20, 2020
1 parent b334095 commit 8ad88cd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions M2/Macaulay2/d/stdiop.d
Original file line number Diff line number Diff line change
Expand Up @@ -127,12 +127,12 @@ cleanscreen():void := (
printMessage(position:Position,message:string):void := (
if !SuppressErrors then (
cleanscreen();
stderr << position;
if recursionDepth > 0 then stderr << "[" << recursionDepth << "]:";
stdError << position;
if recursionDepth > 0 then stdError << "[" << recursionDepth << "]:";
-- gettid() is not there in Solaris
-- tid := gettid();
-- if tid != -1 && tid != getpid() then stderr << "<" << gettid() << ">:";
stderr << " " << message << endl;
-- if tid != -1 && tid != getpid() then stdError << "<" << gettid() << ">:";
stdError << " " << message << endl;
);
);
export printErrorMessage(position:Position,message:string):void := (
Expand Down
2 changes: 1 addition & 1 deletion M2/Macaulay2/m2/testing.m2
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ captureTestResult := (desc, teststring, pkg, usermode) -> (
if isCapturable(teststring, pkg, true) then (
stderr << commentize pad("capturing " | desc, 72) << flush;
(err, output) := capture(teststring, Package => pkg, UserMode => usermode);
if err then printerr "capture failed; retrying in a subprocess ..." else return true);
if err then printerr "capture failed; retrying ..." else return true);
-- fallback to using an external process
stderr << commentize pad("running " | desc, 72) << flush;
runString(teststring, pkg, usermode))
Expand Down

0 comments on commit 8ad88cd

Please sign in to comment.