[llvm-commits] [llvm] r103427 - /llvm/trunk/test/Other/2010-05-60-Printer.ll

David Greene greened at obbligato.org
Mon May 10 20:25:28 PDT 2010


On Monday 10 May 2010 15:51:06 Chris Lattner wrote:
> Author: lattner
> Date: Mon May 10 15:51:06 2010
> New Revision: 103427
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=103427&view=rev
> Log:
> fix a pretty obvious typo.  We test things before committing them, right?

Yes we do.  For three days, in fact.  The sarcasm isn't helping anyone.

This is not a typo.  It's deliberate.

>From http://www.llvm.org/docs/TestingGuide.html:

  As with a Unix shell, the RUN: lines permit pipelines and I/O redirection to   
  be used. However, the usage is slightly different than for Bash. To check 
  what's legal, see the documentation for the Tcl exec command and the 
  tutorial. The major differences are:

  You can't do 2>&1. That will cause Tcl to write to a file named &1. Usually 
  this is done to get stderr to go through a pipe. You can do that in tcl with 
  |& so replace this idiom: ... 2>&1 | grep with ... |& grep

  You can only redirect to a file, not to another descriptor and not from a 
  here document.

  tcl supports redirecting to open files with the @ syntax but you shouldn't 
  use that here.

Then from the linked http://www.tcl.tk/man/tcl8.5/TclCmd/exec.htm#M2:

  2>@1
  Standard error from all commands in the pipeline is redirected to the 
  command result. This operator is only valid at the end of the command 
  pipeline.

The only thing I can imagine being wrong here is a different interpretation
of what "open file" means.

In fact, your solution explicitly violates the testing documentation.  That's 
why I didn't use it.

                                       -Dave




More information about the llvm-commits mailing list