1 package edu.berkeley.sbp.bind;
3 import edu.berkeley.sbp.util.*;
4 import edu.berkeley.sbp.*;
5 import edu.berkeley.sbp.chr.*;
6 import edu.berkeley.sbp.bind.*;
8 import java.lang.annotation.*;
9 import java.lang.reflect.*;
14 * Constructors, classes, and methods with this attribute will
15 * match every production of the nonterminal called "value()"
16 * that is arg-compatible. If value() is undefined, then the
17 * class/constructor/method name is used.
20 @Retention(RetentionPolicy.RUNTIME) public static @interface nonterminal { String value() default ""; }
23 @Retention(RetentionPolicy.RUNTIME) public static @interface raw { }
26 * Constructors, classes, and methods with this attribute will
27 * match every tree tagged with "value()" that is arg-compatible.
28 * If value() is undefined, then the class/constructor/method
32 @Retention(RetentionPolicy.RUNTIME) public static @interface as { String value() default ""; }
36 * If any parameter to a method or field in a class has a named
37 * arg-tag, that parameter/field matches the child of the tree
38 * which either has that label or else is a reference to a
39 * nonterminal with the corresponding name.
41 * The remaining non-named arg-tags match the remaining children
42 * of the tree in sequential order.
44 * If any arg-tagged parameters/fields remain, the match fails.
45 * If there were no arg-tagged parameters-fields, it is as if all
46 * of them were non-named and arg-tagged.
48 * A method/constructor is arg-compatible if all of its arguments
51 * A class is arg-compatible if all of its fields are
52 * arg-compatible, or if one of its constructors is arg-compatible.
55 @Retention(RetentionPolicy.RUNTIME) public static @interface arg { String value() default ""; }