diff options
author | Miguel de Icaza <miguel@gnome.org> | 2002-01-28 17:03:27 +0300 |
---|---|---|
committer | Miguel de Icaza <miguel@gnome.org> | 2002-01-28 17:03:27 +0300 |
commit | 51c3b0cb84ed625b6f25fa6d159c6eea2724c283 (patch) | |
tree | d2f9710ef9ed911dfe70c3e6515597aab25d26b0 /mcs/errors/cs0214.cs | |
parent | d9fd81429bd860171752d859c6c5a0ebe9ef4ff0 (diff) |
2002-01-28 Miguel de Icaza <miguel@ximian.com>
* support.cs: Api for Pair to set a value. Despite the fact that
the variables are public the MS C# compiler refuses to compile
code that accesses the field if the variable is part of a foreach
statement.
* statement.cs (Fixed): Begin implementation of the fixed
statement.
(Block.AddVariable): Return the VariableInfo on success and null
on failure instead of true/false.
* cs-parser.jay (foreach): Catch errors on variables already
defined (we were ignoring this value before) and properly unwind
the block hierarchy
(fixed_statement): grammar for the fixed statement.
svn path=/trunk/mcs/; revision=2183
Diffstat (limited to 'mcs/errors/cs0214.cs')
-rw-r--r-- | mcs/errors/cs0214.cs | 23 |
1 files changed, 4 insertions, 19 deletions
diff --git a/mcs/errors/cs0214.cs b/mcs/errors/cs0214.cs index e71b5f53af4..08eb088af39 100644 --- a/mcs/errors/cs0214.cs +++ b/mcs/errors/cs0214.cs @@ -1,20 +1,5 @@ -// cs0214.cs : Pointers may only be used in an unsafe context -// Line : 14 - -using System; -using System.Reflection; - -public class Blah { - - public static void Main () - { - int* i; - int foo = 10; - - i = &foo; - - Console.WriteLine ("The pointer value is " + i); - } +// cs0214: Pointer can only be used in unsafe context +// Line: 4 +class X { + void *a; } - - |