OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.5.1/] [gcc/] [testsuite/] [gcc.c-torture/] [compile/] [pta-1.c] - Blame information for rev 298

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 297 jeremybenn
typedef struct JSObject JSObject;
2
typedef struct JSObjectMap *(*JSNewObjectMapOp) (JSObject *obj);
3
typedef JSObject *(*JSGetMethodOp) (JSObject *obj);
4
struct JSObjectOps {
5
    JSNewObjectMapOp newObjectMap;
6
};
7
struct JSXMLObjectOps {
8
    struct JSObjectOps base;
9
    JSGetMethodOp getMethod;
10
};
11
struct JSObjectMap {
12
    struct JSObjectOps *ops;
13
};
14
struct JSObject {
15
    struct JSObjectMap *map;
16
};
17
 
18
struct JSXMLObjectOps js_XMLObjectOps;
19
 
20
 
21
/* We need to create SFT's for the entire structure when this address is taken,
22
   not just the part in the component reference itself.  */
23
JSObject *JS_GetMethod(JSObject *obj)
24
{
25
    if (obj->map->ops == &js_XMLObjectOps.base) {
26
        struct JSXMLObjectOps *ops;
27
        ops = (struct JSXMLObjectOps *) obj->map->ops;
28
        obj = ops->getMethod(obj);
29
    }
30
    return obj;
31
}

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.