C# 3.0 updates
[mono.git] / mono / tests / verifier / make_stack_0_test.sh
index 33c6650ab6f5fefb13ae0794e7566407dfe37823..917dde880787b96d5ecd0a6ff8885217620b7070 100755 (executable)
@@ -1,27 +1,34 @@
 #! /bin/sh
 
-TEST_OP=$1
+TEST_VALIDITY=$1
+TEST_OP=$2
 
 TEST_OP_SHORT=`echo $TEST_OP | cut -d " " -f 1`
-TEST_FILE=`echo invalid_stack_0_${TEST_OP_SHORT} | sed -e "s/ /_/g" -e "s/\./_/g" -e "s/&/mp/g"`_generated.cil
+TEST_FILE=`echo ${TEST_VALIDITY}_stack_0_${TEST_OP_SHORT} | sed -e "s/ /_/g" -e "s/\./_/g" -e "s/&/mp/g"`_generated.il
 echo $TEST_FILE
-sed -e "s/OPCODE/${TEST_OP}/g" > $TEST_FILE <<//EOF
+sed -e "s/OPCODE/${TEST_OP}/g" -e "s/VALIDITY/${TEST_VALIDITY}/g" > $TEST_FILE <<//EOF
 // invalid CIL which breaks the ECMA-335 rules. 
 // This CIL should fail verification by a conforming CLI verifier.
 
+.assembly '${TEST_NAME}_generated'
+{
+  .hash algorithm 0x00008004
+  .ver  0:0:0:0
+}
+
 .class Class extends [mscorlib]System.Object
 {
     .field public int32 fld
 }
 
-.method public static int32 Main(int32 arg) cil managed
+.method public static int32 Main() cil managed
 {
        .entrypoint
        .maxstack 1
        .locals init (
            int32 V_0
        )
-       OPCODE // invalid, stack empty.
+       OPCODE // VALIDITY, stack empty.
        ldc.i4.0
        ret
 }