On Sat, Sep 22, 2012 at 4:46 PM, Jed Brown <span dir="ltr"><<a href="mailto:jedbrown@mcs.anl.gov" target="_blank">jedbrown@mcs.anl.gov</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="gmail_quote"><div class="im">On Sat, Sep 22, 2012 at 3:40 PM, Matthew Knepley <span dir="ltr"><<a href="mailto:knepley@gmail.com" target="_blank">knepley@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">

<div class="gmail_quote"><div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="gmail_quote"><div>Well, you wrote</div><div><br></div><div>  PetscInt imid = ((unsigned PetscInt) imin + (unsigned PetscInt) imax) >> 1;</div>

<div><br></div><div>which doesn't compile because the unsigned keyword does not apply to typedefs.</div>
</div></blockquote><div><br></div></div><div>Compiled fine for me.</div></div></blockquote><div><br></div></div><div>Bull. Shit.</div><div><br></div><div>/home/jed/petsc-tmp/src/sys/utils/sorti.c: In function ‘PetscFindInt’:</div>

<div>/home/jed/petsc-tmp/src/sys/utils/sorti.c:162:32: error: expected ‘)’ before ‘PetscInt’</div><div>/home/jed/petsc-tmp/src/sys/utils/sorti.c:162:59: error: expected ‘)’ before ‘PetscInt’</div></div></blockquote><div>
<br></div><div>I was not sure that would work, but of course I tried it before pushing:</div><div><br></div><div><div>  Compiling C files ['/PETSc3/petsc/petsc-dev-pylith/src/sys/utils/sorti.c']</div><div>        Pushing language Cxx</div>
<div>/PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/bin/mpicxx -c -I/PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/include -I/PETSc3/petsc/petsc-dev-pylith/include -I/PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/include -I/PETSc3/petsc/petsc-dev-pylith/include/sieve -I/PETSc3/petsc/exodusii-4.98/include -I/PETSc3/petsc/exodusii-4.98/cbind/include -I/PETSc3/petsc/exodusii-4.98/forbind/include   -Wall -Wwrite-strings -Wno-strict-aliasing -Wno-unknown-pragmas -g  -PIC      -MMD -D__INSDIR__= /PETSc3/petsc/petsc-dev-pylith/src/sys/utils/sorti.c</div>
<div>sh: /PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/bin/mpicxx -c -I/PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/include -I/PETSc3/petsc/petsc-dev-pylith/include -I/PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/include -I/PETSc3/petsc/petsc-dev-pylith/include/sieve -I/PETSc3/petsc/exodusii-4.98/include -I/PETSc3/petsc/exodusii-4.98/cbind/include -I/PETSc3/petsc/exodusii-4.98/forbind/include   -Wall -Wwrite-strings -Wno-strict-aliasing -Wno-unknown-pragmas -g  -PIC      -MMD -D__INSDIR__= /PETSc3/petsc/petsc-dev-pylith/src/sys/utils/sorti.c</div>
<div>Executing: /PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/bin/mpicxx -c -I/PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/include -I/PETSc3/petsc/petsc-dev-pylith/include -I/PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/include -I/PETSc3/petsc/petsc-dev-pylith/include/sieve -I/PETSc3/petsc/exodusii-4.98/include -I/PETSc3/petsc/exodusii-4.98/cbind/include -I/PETSc3/petsc/exodusii-4.98/forbind/include   -Wall -Wwrite-strings -Wno-strict-aliasing -Wno-unknown-pragmas -g  -PIC      -MMD -D__INSDIR__= /PETSc3/petsc/petsc-dev-pylith/src/sys/utils/sorti.c</div>
<div>sh: </div><div>        Popping language Cxx</div><div>        Moving sorti.o to /PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/lib/libpetsc-obj/sorti.o</div><div>        Moving sorti.d to /PETSc3/petsc/petsc-dev-pylith/arch-sieve-fdatatypes-debug/lib/libpetsc-obj/sorti.d</div>
</div><div><br></div><div>   Matt</div><div> </div></div>-- <br>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>
-- Norbert Wiener<br>