class ParamAttribute inherits Attribute cue init .init(0) cue init(value as int) base.init _value = value pro value from var as int class Test def main for method in .typeOf.getMethods if method.name.startsWith('Has_') parts = method.name.split(c'_') attrName = parts[1] value = int.parse(parts[2]) found = false for param in method.getParameters for attr in param.getCustomAttributes(true) if attr.typeOf.name == attrName pa = attr to ParamAttribute assert pa.value == value found = true break assert found def has_ParamAttribute_0(x as String has ParamAttribute) pass def has_ParamAttribute_1(x as String has ParamAttribute(1)) pass