On 6/26/05, Michael G Schwern <[EMAIL PROTECTED]> wrote:
> > For 3, it looks like B::Deparse does't handle the data at all so even
> > if the deparsed subs are identical they may behave totally
> > differently.
> 
> This will simply have to be a caveat.  Fortunately, if B::Deparse ever gets
> this right we'll immediately benefit.

I'm not sure there is a right way to deparse closures (in general).
For example if a variable is shared between 2 closures then it only
makes sense to deparse both of them together. Deparsing them in turn
will lose the sharedness info.

How many people would actually understand that caveat?

I'm ok with "your test will fail even though you'd think it would
pass" (the current situation) but  I don't like "your test will pass
even though it should fail". The former means you need to test in a
different way and you know about it straight away, the latter means
you're not sure that your tests really passed at all.

> > For 2 B::Deparse works and might be the only way but then again, it
> > might be better to just get access to the original string of code
> > before it gets compiled,
> 
> If they want to compare the original string they should have put it in their
> data structure.  Simp.

That is exacltly what I was suggesting,

F

Reply via email to