Clarification: k and v contents may be modified after returning from Set.

Abierto
#69 2 comentarios 2 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
1/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
35/100
Tipo de issue
Documentación
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
go

Línea de trabajo

Review the documentation for Set and the other methods with the same descriptor, starting with the wording quoted in the issue. Confirm how the methods handle the k and v byte arrays, then revise the text so readers do not interpret it as the methods modifying those arrays; done means the ownership and reuse behavior is unambiguous.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Several methods have a similar descriptor to the following in the docs:

k and v contents may be modified after returning from Set.

Upon first reading, I assumed that the Set() method would modify the k and v byte arrays and copies should be passed into the fastcache methods.

I couldn't believe it and only after spending some time digging in the source did I realize that these sentences probably meant that the fastcache methods themselves stored copies of the k and v arrays and that you didn't have to worry about reusing the originals.

Just a heads up, I found the particular wording confusing, perhaps consider a slightly different wording.

Lenguaje dominante
Go
Estrellas
2.4k
Forks
199
Métricas de merge de PR
Sin PR fusionados en 30 d

Preparar el entorno

Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de VictoriaMetrics/fastcache

Todos los issues de VictoriaMetrics/fastcache

Issues similares

Más issues de Go

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.