function Optional< T & [SWS_CORE_01167]
T const * operator-> () const noexcept;
As per corresponding usage in [optional]
The member access operator operator-> of template class ara::core::Optional<T &> serves for synchronous access to members of the referenced object [SWS_CORE_01167]. The function is defined in header #include "ara/core/optional.h", belongs to the scope of ara::core::Optional<T &>, and expects no parameters [SWS_CORE_01167]. The return value provided is a pointer of type T const *, enabling direct read access to the underlying target object [SWS_CORE_01167]. The return type thus corresponds to a pointer to constant data, which prevents modifying accesses via this operator.
Regarding error handling, the method is declared as noexcept and classified as exception safe [SWS_CORE_01167]. However, if the instance does not contain a value (If *this does not contain a value), the specification documents a IsoStdBadOptionalAccessViolation as a violation [SWS_CORE_01167]. Consequently, before dereferencing, the using software must ensure that the optional reference is validly engaged in order to reliably avoid error states at runtime.
For concurrency and calling context, the specification mentions no special protection mechanisms; presumably, the const operation provides no internal synchronization against concurrent modifications [SWS_CORE_01167]. Question Q-0ebf3ed1284fc0c1 (open) The general behavior follows the corresponding usage of the C++ standard for optional types (As per corresponding usage in [optional]) [SWS_CORE_01167].
This usage note was generated automatically based on the AUTOSAR R25-11 specification.
| Header-Datei | #include "ara/core/optional.h" |
|---|---|
| Scope | class ara::core::Optional< T & > |
| Exception-Sicherheit | exception safe |
| Verletzungen (Violations) | IsoStdBadOption- If *this does not contain a value alAccessViolation |
Request a governed re-review of this record. The record is not changed immediately.
- Record
AUTOSAR/AP/record/SWS_CORE_01167- Status
- valid/unmigrated
- Version
AUTOSAR/AP/record/SWS_CORE_01167@rel:R25-11#453ae4da- Content hash
453ae4da- Source
- https://www.autosar.org/fileadmin/standards/R25-11/AP/AUTOSAR_AP_SWS_Core.pdf#nameddest=SWS_CORE_01167
Status: valid/unmigrated
Version: rel:R25-11#619d01d4
Versionshistorie & Revisions (1 transition, 3 revision)
- Current State
valid/unmigrated- Reason
- mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record
- Campaign
2026-08-13-status-backfill- Active Version
AUTOSAR/AP/record/SWS_CORE_01167@rel:R25-11#619d01d4
Recorded Revisions (3):
- R25-11
rel:R25-11#453ae4da2026-09-30 - R24-11
rel:R24-11#70a745e42026-10-14 - R25-11
rel:R25-11#619d01d42026-10-14 active
Requirement Text as-of this release:
Curation Decisions:
Reachable Artifacts & Dependents:
| Date | Actor | Transition | Reason / Rationale | Campaign |
|---|---|---|---|---|
| 2026-08-13 | tool | none → valid/unmigrated | mechanically backfilled by migriere_status_backfill.py -- no per-field curation history exists yet for this record | 2026-08-13-status-backfill |
gemini-3.8-flash-low· 2026-10-13 · German original