Compatibility: do not use `Delay waitForMilliseconds: x`
...and use `(Delay forMilliseconds: x) wait` as the latter is more portable.
--- a/GDBDebugger.st Mon Jul 31 18:09:07 2023 +0100
+++ b/GDBDebugger.st Fri Aug 04 22:56:43 2023 +0100
@@ -1379,7 +1379,7 @@
connection eventPumpStart.
connection eventDispatchStart.
- Delay waitForMilliseconds:100.
+ (Delay forMilliseconds: 100) wait.
connection inferiorPTY notNil ifTrue:[
self send: (GDBMI_inferior_tty_set arguments: (Array with: connection inferiorPTY name)).
@@ -1613,7 +1613,7 @@
"/ Since this method is not required to be 100% accurate, polling seems
"/ like an easy and safe approach. It's not meant for normal usage, anyway.
- [ self hasPendingCommands ] whileTrue:[ Delay waitForMilliseconds: 100 ].
+ [ self hasPendingCommands ] whileTrue:[ (Delay forMilliseconds: 100) wait ].
"Created: / 23-01-2019 / 21:03:57 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!
@@ -1630,7 +1630,7 @@
"/ Since this method is not required to be 100% accurate, polling seems
"/ like an easy and safe approach. It's not meant for normal usage, anyway.
- [ self hasPendingEvents ] whileTrue:[ Delay waitForMilliseconds: 100 ].
+ [ self hasPendingEvents ] whileTrue:[ (Delay forMilliseconds: 100) wait ].
"Created: / 23-01-2019 / 21:03:36 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !
--- a/tests/GDBDebuggerTestsR.st Mon Jul 31 18:09:07 2023 +0100
+++ b/tests/GDBDebuggerTestsR.st Fri Aug 04 22:56:43 2023 +0100
@@ -196,7 +196,7 @@
debugger send: (GDBMI_gdb_exit new) andWait: false.
[ debugger isConnected and:[timeToExit < 2000] ] whileTrue:[
Logger trace:'Still connected...'.
- Delay waitForMilliseconds: 200.
+ (Delay forMilliseconds: 200) wait.
timeToExit := timeToExit + 200.
].
self assert: timeToExit < 2000.
@@ -357,7 +357,7 @@
self assert: debugger breakpoints size == 1.
"/ We need to wait a until breakpoint-modifed
"/ event is received.
- Delay waitForMilliseconds: 200.
+ (Delay forMilliseconds: 200) wait.
self assert: debugger breakpoints first enabled == false.
debugger send: 'c' andWaitFor: GDBThreadGroupExitedEvent.
--- a/tests/GDBInternalPipeStreamTests.st Mon Jul 31 18:09:07 2023 +0100
+++ b/tests/GDBInternalPipeStreamTests.st Fri Aug 04 22:56:43 2023 +0100
@@ -337,7 +337,7 @@
t2 resume.
t1stepper signal.
- Delay waitForMilliseconds:100.
+ (Delay forMilliseconds: 100) wait.
t2stepper signal.
t1blocker wait.
@@ -377,7 +377,7 @@
t2 resume.
t2stepper signal.
- Delay waitForMilliseconds:100.
+ (Delay forMilliseconds: 100) wait.
t1stepper signal.
@@ -424,7 +424,7 @@
t2 resume.
t1stepper signal.
- Delay waitForMilliseconds:100.
+ (Delay forMilliseconds: 100) wait.
t2stepper signal.
@@ -471,7 +471,7 @@
t2 resume.
t2stepper signal.
- Delay waitForMilliseconds:100.
+ (Delay forMilliseconds: 100) wait.
t1stepper signal.
@@ -518,7 +518,7 @@
t2 resume.
t1stepper signal.
- Delay waitForMilliseconds:100.
+ (Delay forMilliseconds: 100) wait.
t2stepper signal.
@@ -565,7 +565,7 @@
t2 resume.
t2stepper signal.
- Delay waitForMilliseconds:100.
+ (Delay forMilliseconds: 100) wait.
t1stepper signal.