JuliaRandom / JuliaRandom/RandomNumbers.jl

Change name of supertype AbstractRNG?

Aperta
#35 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Julia
Stelle
100
Fork
23
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

I think "re-using" the name `AbstractRNG` is not ideal:
`abstract type AbstractRNG{T<:Number} <: Base.Random.AbstractRNG end`

`AbstractRNG` is defined and exported by `Base` and `RandomNumbers`

```
using RandomNumbers
AbstractRNG
```
results in following:
```
WARNING: both RandomNumbers and Base export "AbstractRNG"; uses of it in module Main must be qualified
ERROR: UndefVarError: AbstractRNG not defined
```

Thus code that uses `AbstractRNG` without `RandomNumbers`, will no longer work when `using RandomNumbers`, without explicitly qualifying. i.e. that code will need modifying.

This can be problematic when one doesn't have access to the modules containing references to `AbstractRNG`.

Maybe this is some form of type piracy?

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Direzione di ricerca

Start by reviewing the exported AbstractRNG definition shown in the issue and comparing it with Base.Random.AbstractRNG. Determine an unambiguous replacement and assess the impact on code that imports RandomNumbers; done means the export collision is resolved with compatibility implications documented.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
julia
Ambito
developer-experience
Tipo di issue
Refactoring
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.