InlineAnnotation¶
- class tket.metadata.InlineAnnotation(*args, **kwargs)[source]¶
Bases:
Metadata[Literal[‘never’] |Literal[‘best_effort’]]Metadata hinting the compiler that a function declaration should be inlined at its call sites.
When a function is not annotated, we use a heuristic to determine whether to inline.
Values: - “never”: Never inline this function. - “best_effort”:
Inline the function if possible. This is not guaranteed, the compiler may choose not to inline functions with this annotation.
- ALIASES: ClassVar[list[str]] = []¶
Other aliases of the metadata key.
Typed metadata reads use these, in order, as fallbacks when KEY is not present. This is used for backward compatibility when renaming metadata keys.
Writes ignore this field and only write to KEY.
- KEY: ClassVar[str] = 'tket.inline'¶
The unique key associated with the metadata entry.
- __init__(*args, **kwargs)¶