[ic] Frustrated with IC 4.8

Jon Jensen interchange-users@interchange.redhat.com
Tue Sep 18 23:45:01 2001


On Tue, 18 Sep 2001, Jim Balcom wrote:

> Nope! While my reference was slightly off-target, your memory is also bad.

I remember this distinctly, Jim. I believe both the docs and the code are
fine in this instance. It's embarrassing to even be discussing this kind
of minutiae that will never affect anyone. But here I am doing it anyway.
:)

> Here is a piece of a message near the end of our discussion:
> ----------------------
> > > What I propose it to read is:
> > >
> > > 'While '<!--[' and '[' are interchangeable, the Interchange parser does
> > > not replace ']-->' with ']' unless it sees '<!--[' previously on the
> > > page.' (Change 'elsewhere' to 'previously')
> >
> > I see what you mean, but it's not actually correct. The code looks to see
> > if <!--[ appears *anywhere* on the page, before replacing each ]--> and
> > <!--[, regardless of whether they're in pairs or not.
> >
> > Whether this is the best way in the world to do this or not, Bill was
> > making the docs state how the code actually works.
> >
> > I'll change it to say:
> >
> > ... unless it also sees '<!--[' at least once somewhere on the page.
>
> ------------------------
>
> I couldn't interpret this at the time that we were discussing it, and I
> can't interpret it now, other than the fact that what appears on the page
> has an excellent opportunity to be vastly different than expected.

The revised text you quote me saying above is correct. And even though I
didn't change the code and instead fixed the docs, the parsing will
proceed just as expected. There difference between the words 'elsewhere'
and 'previously' in that documentation snippet is important, but it's
really not important to 99 44/100 % of the users out there. I'm going to
let the other .66% who care just read the code -- it's not worth talking
about here.

> JJ>>Now to your sample snippet:
> JJ>>
> JJ>>> (snippet)
> JJ>>> some code and stuff for the page
> JJ>>> more stuff
> JJ>>> [/comment]
> JJ>>> more lines of stuff
> JJ>>> [comment]
> JJ>>> We are giving away money today
> JJ>>> [/comment]
> JJ>>>
> JJ>>> Now, because there is a [/comment] on the page before [comment] the
> JJ>>> [comment] is shut off immediately. To me, this is stupid behavior and needs
> JJ>>> to be corrected. The Akopia employees writing the documentation chose to not
> JJ>>> do anything about it.
> JJ>>
> JJ>>I don't know what you're talking about here. When I try that exact
> JJ>>snippet, the only noteworthy effect is that a literal '[/comment]' is
> JJ>>printed after 'more stuff', which is just what I'd expect when there was
> JJ>>no opening [comment] tag to begin with. The real comment container below
> JJ>>properly removes 'We are giving ...' from the output, as it should.
>
> I miswrote this. It needs to be used in conjunction with '<!--[' in order
> for this to happen. Otherwise, it's correct.

Oh, now I understand what you were getting at. But the test works either
way. It's a darn easy test for anyone to do, I might add -- just throw
this on a page and try it out. It'll make more sense if you use something
other than the [comment] tag, though, since that just goes away.

So this new version:

(snippet)
some code and stuff for the page
more stuff
<!--[/comment]-->
more lines of stuff
<!--[comment]-->
We are giving away money today
<!--[/comment]-->

... will work exactly the same way as the one you originally (mis)quoted.
It's enough to say you can put ITL inside HTML comments for whatever weird
reason you have, and the HTML comment markers will be stripped off. I
think we wanted to deprecate this feature, but now it's been blasted all
over the mailing lists and it'll be the most popular Interchange feature
of the year, and we'll never get rid of it. :)

> I would like it to need to see an opener followed by a closer and to ignore
> what falls in between, rather than to accept a closer followed by an opener
> and ignoring who knows what?

That's what happens, so I guess we're all happy.

It's been fun reminiscing with you, Jim. :)

Jon