view lphobos/ldc-build @ 1226:00f377e03423

Fix a problem which occurred when a function type was forward-referenced by parameter types. This was intended to fix the following test case: {{{ void delegate(Hit) dg; struct Hit { void delegate(Hit) a; } }}} which ChristianK reduced from a problem downs had on IRC. It also seems to fix mini/compile_delegate.d (which turns out to be quite similar, but produced a different error message).
author Frits van Bommel <fvbommel wxs.nl>
date Sun, 19 Apr 2009 23:15:03 +0200
parents d8a1481eaa0c
children
line wrap: on
line source

#!/bin/sh
export PATH=$PATH:/opt/llvm/bin
export FILE=$1; shift
export LDC_PATH=~/ldc
PARAM=$(for p_file in $($LDC_PATH/bin/ldc $FILE -I~/ldc/lphobos -c -v -of/dev/null |grep import \
        |sed -e "s/import *//" -e "s/\t.*//" \
        |sed -e "s/\./\//g" -e "s/$/\.d/"); do if [ -f $p_file ]; then echo $p_file; fi; done)
echo ldc $FILE $@ $PARAM
$LDC_PATH/bin/ldc $FILE $@ $PARAM