Skip to content

Commit

Permalink
[Fortran API] add default initializers and make member variables priv…
Browse files Browse the repository at this point in the history
…ate (#1005)

* add default initializers and make member variables private in opaque data types
  • Loading branch information
fstein93 authored Jul 16, 2024
1 parent be0b3f8 commit 56ab2f5
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/api/sirius.f90
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,20 @@ module sirius

!> @brief Opaque wrapper for simulation context handler.
type sirius_context_handler
type(C_PTR) :: handler_ptr_
private
type(C_PTR) :: handler_ptr_ = C_NULL_PTR
end type

!> @brief Opaque wrapper for DFT ground statee handler.
type sirius_ground_state_handler
type(C_PTR) :: handler_ptr_
private
type(C_PTR) :: handler_ptr_ = C_NULL_PTR
end type

!> @brief Opaque wrapper for K-point set handler.
type sirius_kpoint_set_handler
type(C_PTR) :: handler_ptr_
private
type(C_PTR) :: handler_ptr_ = C_NULL_PTR
end type

!> @brief Free any of the SIRIUS handlers (context, ground state or k-points).
Expand Down

0 comments on commit 56ab2f5

Please sign in to comment.