Immutable function arguments and variables

  1. Dev A: “Fortran is totally outdated.”
  2. Dev B: “I wish we could declare objects in function arguments or variable values as immutable in Java and Javascript.”

Fortran developer silently wheeps:

! immutable 2D array as argument in Fortran
  integer, intent(in) :: arg(:,:)
! constant value
  character(len=10), parameter :: numbers = "0123456789"

See parameter vs. intent(in).

(yes, I’m currently reading a Javascript book)

Inhalt abgleichen
Willkommen im Weltenwald!

Beliebte Inhalte news

Draketo neu: Beiträge