1.1 --- a/templates/progops.h Tue Mar 21 01:15:38 2017 +0100
1.2 +++ b/templates/progops.h Tue Mar 21 18:45:42 2017 +0100
1.3 @@ -24,7 +24,7 @@
1.4
1.5 /* Generic instantiation operations, defining common members. */
1.6
1.7 -__attr __new(const __table *table, __ref cls, size_t size);
1.8 +__attr __new(const __table *table, __ref cls, size_t size, int immutable);
1.9 __attr __new_wrapper(__ref context, __attr attr);
1.10
1.11 /* Generic internal data allocation. */
1.12 @@ -77,7 +77,8 @@
1.13
1.14 /* Convenience definitions. */
1.15
1.16 -#define __NEWINSTANCE(__CLS) __new(&__InstanceTable_##__CLS, &__CLS, sizeof(__obj_##__CLS))
1.17 +#define __NEWINSTANCE(__CLS) __new(&__InstanceTable_##__CLS, &__CLS, sizeof(__obj_##__CLS), 0)
1.18 +#define __NEWINSTANCEIM(__CLS) __new(&__InstanceTable_##__CLS, &__CLS, sizeof(__obj_##__CLS), 1)
1.19 #define __ISINSTANCE(__ATTR, __TYPE) __BOOL(__fn_native_introspection_isinstance((__attr[]) {__NULL, __ATTR, __TYPE}))
1.20
1.21 #endif /* __PROGOPS_H__ */