Closed xplshn closed 4 months ago
Should this be just a warning or a full error? I'm on the side of making this a fatal error.
But what if someone wants to use aces
in a script where the charset may be determined by the user or data that could contain repetitions?
Anyways, its up to you to decide this. The first commit makes it a fatal error, the second I thought about the case I just mentioned and decided to make it a warning
But what if someone wants to use aces in a script where the charset may be determined by the user or data that could contain repetitions?
Repeats in a charset make it impossible to decode data. Think of what would happen if two digits looked the exact same: you'd never be sure what number you actually have. Here's another example, what if I encoded with the charset 00
? Any data I put in would just get replaced with zeros, and you'd have no hope of reconstructing what I put in.
Its up to you to decide what to do, the warning could be made into an error and use a simple global bool to have it be a warning in lax situations
This PR fixes https://github.com/quackduck/aces/issues/2