codee-com / codee-com/open-catalog
[Fortran] Check for ACTION specifier in OPEN statements
- Lenguaje dominante
- Fortran
- Estrellas
- 106
- Forks
- 12
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
The `OPEN` statement allows the `ACTION` specifier which can be `READ`, `WRITE`, OR `READWRITE`, analogous to `INTENT(IN)`, `INTENT(OUT)`, and `INTENT(INOUT)` respectively. The programmer knows how an opened file is to be used, and using a file connection in a way contrary to the `ACTION` will produce a runtime error. Adding a check that each `OPEN` includes an `ACTION` could therefore help reveal bugs where a file that is intended to be read-only is written to. This would improve code correctness and security.
It would be even better not to rely on the runtime error, and instead check that no `WRITE` statement is applied to a unit opened as `ACTION='READ'` and vice versa.
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Línea de trabajo
Comienza localizando cómo el analizador gestiona las sentencias Fortran OPEN, ACTION y WRITE. Aclara si el primer cambio debe exigir ACTION, hacer cumplir la coherencia entre READ/WRITE o ambas cosas, y después define pruebas para cada valor de ACTION compatible y los diagnósticos resultantes. Se considera terminado cuando las comprobaciones seleccionadas están cubiertas por pruebas.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- fortran
- Área
- security
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Estado de actividad
- Estancado
- Claridad
- Necesita aclaración
- Aptitud para principiantes
- 25/100