I've modified some OOP macros i found in this forum but i get an error of "unexpected end of file", but i don't know why or where is the error, the macros are the following:
macro class class_name, [class_fields]
{
if defined defining
display '(EEE) en clase ', `class_name, ': clases anidadas no permitidas', 13, 10
end if
defining equ `class_name
current_class fix class_name
struc class_name
__%
.vtable_ptr rd 1
common
class_fields
%__
}
__% fix {
%__ fix }
macro endclass
{
if ~ defined defining
display '(EEE) : macro "endclass" no precedida por macro "class"', 13, 10
end if
restore defining
restore current_class
}
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
I get the error message when i try to create a object instance in this way:
; class definition
class RootClass, \
.fd_counter rb 1 \
.fd_flag rb 1
endclass
; object instances
myObj1 RootClass
myObj2 RootClass
Hope someone can help me.
Thank you all.
|