[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Converting a string to valid XHTML id?
From: |
Lennart Borgman |
Subject: |
Re: Converting a string to valid XHTML id? |
Date: |
Thu, 2 Dec 2010 01:44:12 +0100 |
On Thu, Dec 2, 2010 at 1:12 AM, Davis Herring <address@hidden> wrote:
>>> And my function is injective.
>>
>> Do you mean that it always maps the same original input string to the
>> same unique output string?
>
> Yes -- injective gives you the "unique". The "same" is because it's pure.
>
>> However I thought it would be easier reading the result with my
>> simpler mapping.
>
> Sure, unless this runs too many times.
>
>>>> (when old
>>>> (setq new-id (concat new-id "X"))))
>
> I don't know what's really easier; I just think that having it be
> stateless is a good thing.
I don't understand how your version is supposed to work. How can it be
unique if it does not keep track of if the id is already used? (Or did
you say that this case is not covered?)
- Re: Converting a string to valid XHTML id?, Lennart Borgman, 2010/12/01
- Re: Converting a string to valid XHTML id?, Davis Herring, 2010/12/01
- Re: Converting a string to valid XHTML id?, rm, 2010/12/01
- Re: Converting a string to valid XHTML id?, Davis Herring, 2010/12/01
- Re: Converting a string to valid XHTML id?, Lennart Borgman, 2010/12/01
- Re: Converting a string to valid XHTML id?, Davis Herring, 2010/12/01
- Re: Converting a string to valid XHTML id?, Lennart Borgman, 2010/12/01
- Re: Converting a string to valid XHTML id?, Davis Herring, 2010/12/01
- Re: Converting a string to valid XHTML id?,
Lennart Borgman <=
- Re: Converting a string to valid XHTML id?, Davis Herring, 2010/12/01
- Re: Converting a string to valid XHTML id?, Lennart Borgman, 2010/12/01
Re: Converting a string to valid XHTML id?, Stefan Monnier, 2010/12/01
- Re: Converting a string to valid XHTML id?, Lennart Borgman, 2010/12/01
- Re: Converting a string to valid XHTML id?, Kevin Rodgers, 2010/12/01
- Re: Converting a string to valid XHTML id?, Lennart Borgman, 2010/12/01
- Re: Converting a string to valid XHTML id?, PJ Weisberg, 2010/12/01
- Re: Converting a string to valid XHTML id?, Lennart Borgman, 2010/12/02
- Re: Converting a string to valid XHTML id?, Lawrence Mitchell, 2010/12/02
- Re: Converting a string to valid XHTML id?, Lennart Borgman, 2010/12/02