forked from dolphinsmalltalk/DolphinVM
-
Notifications
You must be signed in to change notification settings - Fork 0
/
STMessage.h
44 lines (30 loc) · 1.09 KB
/
STMessage.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/******************************************************************************
File: STMessage.h
Description:
VM representation of Smalltalk Message class.
N.B. The class here defined is well known to the VM, and must not
be modified in the image. Note also that this class may also have
a representation in the assembler modules (so see istasm.inc)
******************************************************************************/
#ifndef _IST_STMessage_H_
#define _IST_STMessage_H_
#include "STObject.h"
class Message;
typedef TOTE<Message> MessageOTE;
class Message // : public Object
{
public:
SymbolOTE* m_selector;
ArrayOTE* m_args;
enum { MessageSelectorIndex=ObjectFixedSize, MessageArgumentsIndex, FixedSize };
static MessageOTE* New()
{
return reinterpret_cast<MessageOTE*>(ObjectMemory::newPointerObject(Pointers.ClassMessage, FixedSize));
}
static MessageOTE* NewUninitialized()
{
return reinterpret_cast<MessageOTE*>(ObjectMemory::newUninitializedPointerObject(Pointers.ClassMessage, FixedSize));
}
};
ostream& operator<<(ostream& st, const MessageOTE* oteMsg);
#endif //EOF