summaryrefslogtreecommitdiff
path: root/src/Process.hs
diff options
context:
space:
mode:
authorRoman Smrž <roman.smrz@seznam.cz>2022-10-07 11:09:44 +0200
committerRoman Smrž <roman.smrz@seznam.cz>2022-10-07 18:27:32 +0200
commit2143eb381fc28e2d676a9c9a433426b1b2dbf737 (patch)
tree4842e6c9a23d64b98a06c758d85fe9db94d40dad /src/Process.hs
parent4161f5776e5e7a01fb9eb62351c0f648bb918076 (diff)
Process variables and expression type
Diffstat (limited to 'src/Process.hs')
-rw-r--r--src/Process.hs7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/Process.hs b/src/Process.hs
index bb33953..04c5076 100644
--- a/src/Process.hs
+++ b/src/Process.hs
@@ -21,6 +21,7 @@ import System.Posix.Signals
import System.Process
import Output
+import Test
data Process = Process
{ procName :: ProcName
@@ -33,6 +34,12 @@ data Process = Process
instance Eq Process where
(==) = (==) `on` procStdin
+instance ExprType Process where
+ textExprType _ = T.pack "proc"
+ textExprValue n = T.pack "p:" <> textProcName (procName n)
+ emptyVarValue = Process (ProcName T.empty) undefined undefined undefined undefined
+
+
data ProcName = ProcName Text
| ProcNameTcpdump
| ProcNameGDB