def try5():
    d = Definer()
    m = d.matcher
    f1 = CFunc(PrimTypes.INT)
    f1.add(CPtr(CPtr(PrimTypes.VOID)))
    m.add_rule(CPtr(PrimTypes.VOID), 'PVOID')
    m.add_rule(PrimTypes.INT, 'INT')
    m.tree_names_list.append('MYSTRUC')
    # m.add_rule(CPtr(f1), 'MY_PROC')
    s1 = CStruct()
    s1.add(PrimTypes.UINT, 'a')
    u1 = CUnion()
    u1.add(PrimTypes.CHAR, 'b1')
    u1.add(CPtr(CTypeRef('MYSTRUC')), 'b2')
    s1.add(u1, '')
    s1.add(PrimTypes.INT, 'c')
    # mk = BraceDefMaker('TEST_16', s1, d)
    e1 = CEnum()
    e1.add('RED', 10)
    e1.add('GREEN', 20)
    e1.add('BLUE', 30)
    mk = BraceDefMaker('TEST16', e1, d)
    print(mk.typedef())
    print(mk.pure_def())
    print(mk.mixed_def())

# try5()
