Package org.eclipse.cdt.core.parser.util
Class AttributeUtil
java.lang.Object
org.eclipse.cdt.core.parser.util.AttributeUtil
Collection of static methods for dealing with attributes.
- Since:
- 5.4
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionstatic char[]
getSimpleArgument
(IASTAttribute attribute) Returns character representation of the attribute argument, ornull
if the attribute has zero or more than one argument.static boolean
hasAttribute
(IASTAttributeOwner node, String[] names) Returnstrue
if a declarator has an attribute with one of the given names.static boolean
Returnstrue
if the node has a "nodiscard" attribute.static boolean
Returnstrue
if the node has a "noreturn" or "__noreturn__" attribute.
-
Method Details
-
hasAttribute
Returnstrue
if a declarator has an attribute with one of the given names. Thenames
array is assumed to be small. -
hasNoreturnAttribute
Returnstrue
if the node has a "noreturn" or "__noreturn__" attribute. -
hasNodiscardAttribute
Returnstrue
if the node has a "nodiscard" attribute.- Since:
- 7.0
-
getSimpleArgument
Returns character representation of the attribute argument, ornull
if the attribute has zero or more than one argument.
-