Make __field__ take a symbol instead of a string
[fur] / c / environment.h
1 #ifndef ENVIRONMENT_H
2 #define ENVIRONMENT_H
3
4 #include <stdbool.h>
5 #include "symbol.h"
6 #include "object.h"
7
8 struct Environment;
9 typedef struct Environment Environment;
10
11 Environment* Environment_create(Environment*);
12
13 struct EnvironmentGetResult;
14 typedef struct EnvironmentGetResult EnvironmentGetResult;
15 struct EnvironmentGetResult {
16   bool found;
17   Object* value;
18 };
19
20 EnvironmentGetResult Environment_get(Environment*, Symbol*);
21 bool Environment_set(Environment*, Symbol*, Object*);
22
23 #endif