Skip to content

BeamDyn subroutine argument passing #2641

@bjonkman

Description

@bjonkman

While building the dev branch, today, my compiler warned

BeamDyn.f90(2673): warning #6843: A dummy argument with an explicit INTENT(OUT) declaration is not given an explicit value. [RR0META]

The code looks a little unusual. The calling code
is sending m%qp%RR0mEta(:,idx_qp,nelem) as an intent(out) variable (which Fortran could fill with zeros or maybe random values?):

real(BDKi), intent(out) :: RR0mEta(:), rho(:,:)

But then instead of using the Calc_RR0mEta_rho() routine's argument, it sets that same portion of m%qp inside the routine

m%qp%RR0mEta(:,idx_qp,nelem) = MATMUL(RR0, p%qp%mEta(:,idx_qp,nelem))

This should be changed to either (1) use the routine's RR0META variable instead of m%qp%RR0mEta(:,idx_qp,nelem) or (2) remove the routine's RR0META variable

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions