Re: [Mono-winforms-list] Timelines

2005-08-04 Thread Jordi Mas
El dc 03 de 08 del 2005 a les 14:27 -0500, en/na David A. Cornelson
(gmail) va escriure:

 When you get to “1g”, then I’m really going to get excited about using
 mono. When will that be?

Regarding installation since we moved from the approach of implementing
SWF using Wine is much much easier. You really have to have very few
problems installing the stuff.

Regarding when we will hit 1a it's difficult to predict, but it's
influenced by how community helps us with bug reports, testing
applications, and bug fixes.

We have not a date, but if you help it will be quicker :)

Jordi,

-- 
Jordi Mas i Hernàndez - Mono development team - http://www.mono-project.com
Homepage and LiveJournal at http://www.softcatala.org/~jmas


___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list


[Mono-winforms-list] Threading problem

2005-08-04 Thread Paul
Hi,

Is there currently a problem with threading and winforms? If I run an
app which uses System.Threading and winforms, I get the following when I
quit

XIO :  fatal IO error 9 (Bad file descriptor on X server gibberish -
literally!
   after 34932 requests (34923 known processed) with 0 events
remaining.

Is this a known problem?

Using FC4 (rawhide) with mono (checked out from the developer branch at
16:00 British Summer time and compiled with make distclean via my
script)

TTFN

Paul
-- 
Some people will do anything for a woman in uniform - The Doctor -
Unregenerate (Big Finish audio)


signature.asc
Description: This is a digitally signed message part
___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list


Re: [Mono-winforms-list] Threading problem

2005-08-04 Thread Paul
Hi Peter,

 As you may have noticed by now, shutdown is not yet clean. Goes along the 
 lines of the bug you filed about memory stuff on shutdown. Since it's 
 shutdown and the app is done it's not highest on our priority list. It's 
 mostly related to order of window destruction and explicit vs. implicit 
 window destruction.

Wasn't sure, so I thought I'd mention it here first. Thanks for the
heads up.

TTFN

Paul
-- 
Some people will do anything for a woman in uniform - The Doctor -
Unregenerate (Big Finish audio)


signature.asc
Description: This is a digitally signed message part
___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list


Re: [Mono-winforms-list] Threading problem

2005-08-04 Thread Miguel de Icaza
Hello,

 Is there currently a problem with threading and winforms? If I run an
 app which uses System.Threading and winforms, I get the following when I
 quit

Winforms is not a multithreaded toolkit.

You must use Control.Invoke to perform Winform calls from a different
thread.
___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list


Re: [Mono-winforms-list] Re: Ongoing effort to upgrade Cairo to 0.5

2005-08-04 Thread Hisham Mardam Bey
On 8/4/05, Miguel de Icaza [EMAIL PROTECTED] wrote:

 Do you have a sample C# test case to debug this against?
 
If you run anything in System.Drawing you can get to it. I'm testing
with C code for now with something like:

{
GpPen *pen;
GpBrush *brush;
int a = 255;
int r = 255;
int g = 0;
int b = 0;

GdipCreatePen1 (a  24 | r  16 | g  8 | b,
10, UnitPixel, pen);

GdipDrawRectangle (gp, pen, 0, 0, 0, 0);

return;
}


Just add this after 

gp = gdip_graphics_new (surface);

in tests/testgdi.c


 Does Winforms start up with it?


Not yet.

-- 
Hisham Mardam Bey
MSc (Computer Science)
http://hisham.cc/
+9613609386
Codito Ergo Sum (I Code Therefore I Am)
___
Mono-winforms-list maillist  -  Mono-winforms-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-winforms-list


Re: [Mono-devel-list] [PATCH] monodis and JScript.NET assemblies

2005-08-04 Thread Jb Evain

Hey,

Wow, right. Here is a sightly altered version of your alteration, it  
implements detail discussed on irc.


Jb



dis.patch
Description: Binary data



Hi,

The patch skips any marshal info for the return type parameter. Also,
the case that monodis isn't able to handle is when there are no rows
at all in the param table for the method, but method has parameters. I
was handling only the case when rows for some params were missing.

Attached is a proposed altered patch.

-Ankit

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] Graphics merge-in status

2005-08-04 Thread Andrew Skiba
Hello.

Yesterday I finished merging out our changes to System.Drawing. Vast
majority of changes were java-specific.

The next thing I want to do is to commit the drawing tests helper we
started to develop at Mainsoft.

I will create a directory under sys.drawing/test for this helper and
will commit the helper as is. It needs few changes, however, to be
usable for Mono. Today it checks TARGET_JVM to decide whether we are
creating reference results on dotnet, or run tests. Of course, it does
not suite Mono. I'd like to hear your ideas on how better to fix that.

Few words on the idea of this tool.

It is supposed to aid in writing tests that result in drawing. So there
is a class that provides 3 main features:

* Graphics property which can be used for any drawing operations
* Show method that opens a window with the result of the drawing to see
results manually
* Compare methods family - I will explain that in more details below.

So a typical test case will look like:

[Test]
public void DrawRectTest ()
{
DrawingTest t = DrawingTest.Create (200, 200); //create helper
class instance with drawing area of this size

t.Graphics.DrawRectangle (Pens.Blue, 10, 10, 150, 180);
t.Show (); // optional
Assert.IsTrue (t.Compare ());

t.Graphics.DrawRectangle (Pens.Red, 50, 20, 190, 30);
Assert.IsTrue (t.Compare ());
}

Now I will explain what Compare is all about.

When it's run on dotnet, Compare always returns true and as a side
effect it creates expected result named DrawRectTest:X where X is the
sequential number of the call inside DrawRectTest function. The name of
the function is extracted from the call stack.

When it later is run on java, Compare will find the expected result that
dotnet created and compare the FFT of the resulting bitmaps. If the
bitmaps were similar enough, it will return true. There is an overload
with tolerance parameter, for fine-tuning weird tests.

The comparing itself is done very approximately at this stage, actually
it's very easy to confuse the algorithm. It only calculates the sum of
the squares of all FFT values for every picture and compares the sums
for java and dotnet. This was done because it's very easy to keep one
number per expected result.

Any questions and suggestions are welcome.

Andrew.
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] [PATCH] Check for assembly attributes

2005-08-04 Thread Carlos Alberto Cortez
Hello,

Below my comments.

El jue, 04-08-2005 a las 00:46 -0400, Ben Maurer escribió:
 On Wed, 2005-08-03 at 20:55 -0500, Carlos Alberto Cortez wrote:
  Hey,
  
  A patch is attached, containing a check for InternalsVisibleToAttribute,
  when it is applied to an assembly. It reports a warning or shows an
  error, just like csc does.
 
 
 
  +   if (t.Equals (typeof 
  (System.Runtime.CompilerServices.InternalsVisibleToAttribute))) {
 
 This precludes us from using the assembly in mscorlib.dll. It could
 potentially be useful to use there -- say to let us write nunit tests
 that poked at internals.

I'm not very sure about the scenarios you are thinking in. Could you
please show some detailed examples?

 
 See http://blogs.msdn.com/junfeng/archive/2004/09/14/229254.aspx about
 how there is support for handling commas in file names. Your code would
 break under this.

Well, I didn't know about that, but IHMO I find it like a very bad
practice, and I'm sure that there aren't people out there who like to
call their assemblies 'My,Assembly,Version=xx... or something like
that.

Also, to test this, I tried to load an assembly named
'Test,Assembly' (using Assembly.Load ()) in both mono and ..NET, and
neither could load it successfully. The only way to work with it AFAIK
is when you get name of the assembly itself, or use Assembly.LoadFrom.

So, I don't think it's that important. But, if anybody find it
neccessary, we could add it.

 
 Finally, comparisons should be done with the invariant culture.
 
 -- Ben
 

Thanks, I just noted that's the way the comparisons are done in the
runtime.

Carlos.


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] [PATCH] Check for assembly attributes

2005-08-04 Thread Marek Safar

Hello Carlos,


A patch is attached, containing a check for InternalsVisibleToAttribute,
when it is applied to an assembly. It reports a warning or shows an
error, just like csc does.


 


+   if (a == null)
+   throw new ArgumentNullException (a);

This will never happen.

+   if (t.Equals (typeof 
(System.Runtime.CompilerServices.InternalsVisibleToAttribute))) {

Please use direct comparison with type declared in TypeManager. See how it's 
used elsewhere.


+   string [] args = a.GetString ().Trim ().Split 
(new char [] {','});

a.GetString () can return null.

+   CheckAttributeValid (a);

Could you rename the method to be more explicit ?


+   Report.Warning (1700, a.Location, Assembly reference 
' + a.GetString () + ' is invalid and cannot be resolved);

Here you are missing warning level (2nd parameter)



Do you have tests for this ?


Marek




Index: ChangeLog
===
--- ChangeLog   (revisión: 47987)
+++ ChangeLog   (copia de trabajo)
@@ -1,3 +1,9 @@
+2005-08-03  Carlos Alberto Cortez [EMAIL PROTECTED]
+
+   * codegen.cs
+   (AssemblyClass.CheckAttributeValid): New method to check
+   validity in assembly attributes.
+   
2005-08-03  Martin Baulig  [EMAIL PROTECTED]

Make iterators in generic methods work; see gtest-191.cs.
Index: codegen.cs
===
--- codegen.cs  (revisión: 47987)
+++ codegen.cs  (copia de trabajo)
@@ -1186,6 +1186,45 @@
Report.Error (1548, Error during assembly signing.  + 
text);
}

+   void CheckAttributeValid (Attribute a)
+   {
+   if (a == null)
+   throw new ArgumentNullException (a);
+
+   Type t = a.Type;
+   if (t.Equals (typeof 
(System.Runtime.CompilerServices.InternalsVisibleToAttribute))) {
+   string [] args = a.GetString ().Trim ().Split 
(new char [] {','});
+
+   bool is_name_valid = true;
+   bool version = false, culture = false, 
key_token = false;
+   for (int i = 1; i  args.Length; i++) {
+   string [] values = args [i].Split (new 
char [] {'='});
+   if (values.Length  2 || values [1] == 
String.Empty) {
+   is_name_valid = false;
+   break;
+   }
+
+   if (String.Compare (values [0], 
Version, true) == 0)
+   version = true;
+   else if (String.Compare (values [0], 
Culture, true) == 0)
+   culture = true;
+   else if (String.Compare (values [0], 
PublicKeyToken, true) == 0)
+   key_token = true;
+   // PublicKey is the only valid entry
+   else if (String.Compare (values [0], 
PublicKey, true) != 0) {
+   is_name_valid = false;
+   break;
+   }
+   }
+
+   // If the name is invalid, report CS1700
+   if (!is_name_valid || args [0] == )
+   Report.Warning (1700, a.Location, Assembly reference 
' + a.GetString () + ' is invalid and cannot be resolved);
+   else if (culture || key_token || version)
+   throw new Exception (Friend assembly ' + 
a.GetString () + ' is invalid. InternalsVisibleTo cannot have version, culture or key token 
specified.);
+   }
+   }
+
public override void ApplyAttributeBuilder (Attribute a, 
CustomAttributeBuilder customBuilder)
{
if (a.Type.IsSubclassOf (TypeManager.security_attr_type) 
 a.CheckSecurityActionValidity (true)) {
@@ -1196,6 +1235,7 @@
return;
}

+   CheckAttributeValid (a);
Builder.SetCustomAttribute (customBuilder);
}

 




___
Mono-devel-list mailing list

[Mono-devel-list] ThreadAbortException - Why is it rethrown?

2005-08-04 Thread Vivek, Bharath Varma (IE10)
Hi,

I have a question regarding ThreadAbortException. 
Why is the thread abort exception rethrown at the end of a catch clause?
Why is ThreadAbortException's behavior designed to be this way?

Thanks in advance
-Vivek

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] Compiling from sources

2005-08-04 Thread Arnhoffer Károly
Hi all,

I am a very newbie in compiling Mono from sources (I have used RPMs so far) and 
I am not managed to do it successfully.

I have sources from http://go-mono.com/sources/mono-1.1/mono-1.1.8.tar.gz and 
http://mono.ximian.com/daily/mono-1.1.8.20050803.tar.gz and 'make' runs into 
error here:

make[7]: Entering directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make all-local
make[8]: Entering directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[8]: *** No rule to make target 
`System.Security.Cryptography/CryptographicUnexpectedOperationExcpetion.cs', 
needed by `../../class/lib/basic/mscorlib.dll'.  Stop.
make[8]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[7]: *** [do-all] Error 2
make[7]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[6]: *** [all-recursive] Error 1
make[6]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class'
make[5]: *** [all-recursive] Error 1
make[5]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[4]: *** [profile-do--basic--all] Error 2
make[4]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[3]: *** [profiles-do--all] Error 2
make[3]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[2]: *** [all-local] Error 2
make[2]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/runtime'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8'
make: *** [all] Error 2

It seems that files are needed. I found some files in the unpacked archive's 
root. I started to copy them to locations that were turned out while making. 
But it is a very slow practice. How should I do this the best?

Thanks! 

Arnhoffer Károly
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Graphics merge-in status

2005-08-04 Thread Jonathan Pryor
On Thu, 2005-08-04 at 00:06 -0700, Andrew Skiba wrote:
 I will create a directory under sys.drawing/test for this helper and
 will commit the helper as is. It needs few changes, however, to be
 usable for Mono. Today it checks TARGET_JVM to decide whether we are
 creating reference results on dotnet, or run tests. Of course, it does
 not suite Mono. I'd like to hear your ideas on how better to fix that.

Might I suggest that you instead use an explicit update mechanism to
produce the reference results?  Requiring that you create the reference
results requires that you actually have .NET around to produce them
(which may not always be true), and also means that if .NET has a bug we
can't provide a correct fix (bug-for-bug compatibility isn't always
desirable -- see all the fixes made to System.Reflection.Emit).

 - Jon


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


RE: spam: suspected: Re: [Mono-devel-list] Graphics merge-in status

2005-08-04 Thread Andrew Skiba
Hello Jon.

Thanks for your answer.

I understand that ability to run tests without windows box is an
advantage. I thought to commit expected results in similar way we did
with XML tests.

By explicit update mechanism do you mean any particular technique?

Also, how do you suggest to solve the .NET bug problem?

 Might I suggest that you instead use an explicit update 
 mechanism to produce the reference results?  Requiring that 
 you create the reference results requires that you actually 
 have .NET around to produce them (which may not always be 
 true), and also means that if .NET has a bug we can't provide 
 a correct fix (bug-for-bug compatibility isn't always 
 desirable -- see all the fixes made to System.Reflection.Emit).
 
  - Jon
 
 
 
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


AW: [Mono-devel-list] Compiling from sources

2005-08-04 Thread Matthias Felgner
Hi,

please go here

http://www.all-the-johnsons.co.uk/mono/mono-firstcompile.html

and check out this tutorial. I used it and had no problems with it. Also make 
sure to check out the other sections regarding mono on this page.

Note to Paul: Good Work there :-)

Regards,

--Matt

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von Arnhoffer Károly
Gesendet: Donnerstag, 4. August 2005 12:16
An: mono-devel-list@lists.ximian.com
Betreff: [Mono-devel-list] Compiling from sources

Hi all,

I am a very newbie in compiling Mono from sources (I have used RPMs so far) and 
I am not managed to do it successfully.

I have sources from http://go-mono.com/sources/mono-1.1/mono-1.1.8.tar.gz and 
http://mono.ximian.com/daily/mono-1.1.8.20050803.tar.gz and 'make' runs into 
error here:

make[7]: Entering directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make all-local
make[8]: Entering directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[8]: *** No rule to make target 
`System.Security.Cryptography/CryptographicUnexpectedOperationExcpetion.cs', 
needed by `../../class/lib/basic/mscorlib.dll'.  Stop.
make[8]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[7]: *** [do-all] Error 2
make[7]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[6]: *** [all-recursive] Error 1
make[6]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class'
make[5]: *** [all-recursive] Error 1
make[5]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[4]: *** [profile-do--basic--all] Error 2
make[4]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[3]: *** [profiles-do--all] Error 2
make[3]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[2]: *** [all-local] Error 2
make[2]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/runtime'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8'
make: *** [all] Error 2

It seems that files are needed. I found some files in the unpacked archive's 
root. I started to copy them to locations that were turned out while making. 
But it is a very slow practice. How should I do this the best?

Thanks! 

Arnhoffer Károly
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


RE:[Mono-devel-list] Compiling from sources

2005-08-04 Thread Matthias Felgner
Try

svn co http://svn.myrealbox.com/source/trunk/mcs


--Matt
-Ursprüngliche Nachricht-
Von: Arnhoffer Károly [mailto:[EMAIL PROTECTED] 
Gesendet: Donnerstag, 4. August 2005 15:01
An: Matthias Felgner; mono-devel-list@lists.ximian.com
Betreff: RE: [Mono-devel-list] Compiling from sources

Hi,

I can not download from this svn:

[EMAIL PROTECTED]:~ svn co svn://svn.myrealbox.com/source/trunk/mcs
 
svn: Can't connect to host 'svn.myrealbox.com': Connection refused
[EMAIL PROTECTED]:~

:(

Arnhoffer Károly

-Original Message-
From: Matthias Felgner [mailto:[EMAIL PROTECTED]
Sent: Thursday, August 04, 2005 1:45 PM
To: Arnhoffer Károly; mono-devel-list@lists.ximian.com
Subject: AW: [Mono-devel-list] Compiling from sources


Hi,

please go here

http://www.all-the-johnsons.co.uk/mono/mono-firstcompile.html

and check out this tutorial. I used it and had no problems with it. Also make 
sure to check out the other sections regarding mono on this page.

Note to Paul: Good Work there :-)

Regards,

--Matt

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Im Auftrag von Arnhoffer Károly
Gesendet: Donnerstag, 4. August 2005 12:16
An: mono-devel-list@lists.ximian.com
Betreff: [Mono-devel-list] Compiling from sources

Hi all,

I am a very newbie in compiling Mono from sources (I have used RPMs so far) and 
I am not managed to do it successfully.

I have sources from http://go-mono.com/sources/mono-1.1/mono-1.1.8.tar.gz and 
http://mono.ximian.com/daily/mono-1.1.8.20050803.tar.gz and 'make' runs into 
error here:

make[7]: Entering directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make all-local
make[8]: Entering directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[8]: *** No rule to make target 
`System.Security.Cryptography/CryptographicUnexpectedOperationExcpetion.cs', 
needed by `../../class/lib/basic/mscorlib.dll'.  Stop.
make[8]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[7]: *** [do-all] Error 2
make[7]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class/corlib'
make[6]: *** [all-recursive] Error 1
make[6]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs/class'
make[5]: *** [all-recursive] Error 1
make[5]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[4]: *** [profile-do--basic--all] Error 2
make[4]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[3]: *** [profiles-do--all] Error 2
make[3]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/mcs'
make[2]: *** [all-local] Error 2
make[2]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8/runtime'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/mono-1.1.8/mono-1.1.8'
make: *** [all] Error 2

It seems that files are needed. I found some files in the unpacked archive's 
root. I started to copy them to locations that were turned out while making. 
But it is a very slow practice. How should I do this the best?

Thanks!

Arnhoffer Károly ___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com 
http://lists.ximian.com/mailman/listinfo/mono-devel-list
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Error Building

2005-08-04 Thread Rafael Teixeira
Do you have $prefix/bin at the start of your PATH and $prefix/lib
ldconfig'ed? If not probably the monolite installed there may not be
able to actually run, or some mixed pieces from other installations
are entering the process...

Hope It Helps,

:)

On 8/3/05, Jonathan S. Chambers [EMAIL PROTECTED] wrote:
 I'm trying to do a build from SVN on a new machine (FC4). I got the latest 
 from svn, and then I run the following in the mono directory:
 
 ./autogen --with-preview=yes --prefix=/home/jsc/mono_install
 make get-monolite-latest
 make
 
 I get the following error:
 
 make[5]: Entering directory `/home/cmh/mcs'
 *** The compiler 'mcs' doesn't appear to be usable.
 *** The contents of your 'monolite' directory are out-of-date
 *** You may want to try 'make get-monolite-latest'
 make[5]: *** [do-profile-check] Error 1
 make[5]: Leaving directory `/home/cmh/mcs'
 make[4]: *** [profile-do--basic--all] Error 2
 make[4]: Leaving directory `/home/cmh/mcs'
 make[3]: *** [profiles-do--all] Error 2
 make[3]: Leaving directory `/home/cmh/mcs'
 make[2]: *** [all-local] Error 1
 make[2]: Leaving directory `/home/cmh/mono/runtime'
 make[1]: *** [all-recursive] Error 1
 make[1]: Leaving directory `/home/cmh/mono'
 make: *** [all] Error 2
 
 
 Is it because I am trying to install to my home directory? Or is something 
 else wrong?
 
 Thanks,
 Jonathan
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list
 


-- 
Rafael Monoman Teixeira
---
I'm trying to become a Rosh Gadol before my own eyes. 
See http://www.joelonsoftware.com/items/2004/12/06.html for enlightment.
It hurts!
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


RE: [Mono-devel-list] Compiling from sources

2005-08-04 Thread Paul F. Johnson
Hi,

svn is working fine from here.

TTFN

Paul
-- 
Some people will do anything for a woman in uniform - The Doctor -
Unregenerate (Big Finish audio)

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] C or C# and Card Reader

2005-08-04 Thread Alf C Stockton
Would it be possible in a client/server environment, similar to a web 
environment, to create a program on the client that would be called from a web 
page.
This program would read a serial connected card reader, and have that read data 
passed to the server so that the server could retrieve data based on what was 
passed and return same to the client as a web page.


---

Regards,
Alf Stocktonwww.stockton.co.za

Contrary to popular belief, penguins are not the salvation of modern
technology.  Neither do they throw parties for the urban proletariat.

My email disclaimer can be read at: http://www.stockton.co.za/disclaimer.html
If you don't have web access, the disclaimer can be mailed to you on request.

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] RE: [Gc] [PATCH] Race condition when restarting threads

2005-08-04 Thread Boehm, Hans
Sorry about the long delay.

I don't quite understand the problem here.  If GC_stop_count has
just been incremented, then I'm about to send another suspend
signal to the thread, and it will have to stop again before
we think the world is stopped.  

Can you be a bit more specific about the race here?

Thanks.

Hans

 -Original Message-
 From: Ben Maurer [mailto:[EMAIL PROTECTED] 
 Sent: Tuesday, July 12, 2005 11:29 PM
 To: Boehm, Hans
 Cc: [EMAIL PROTECTED]; mono-devel-list@lists.ximian.com
 Subject: RE: [Gc] [PATCH] Race condition when restarting threads
 
 
 On Tue, 2005-07-12 at 11:42 -0700, Boehm, Hans wrote:
   Your patch had the fields set as volatile, so shouldn't the
   compiler ensure that the cpu does not reorder the stores?
  We had a long discussion of that on the C++ memory model list. The 
  answer is architecture dependent.  Volatile will generally prevent 
  compiler reordering.  It usually introduces the necessary hardware 
  barriers on Itanium, but not, for example, on PowerPC.
 
 I think your version has a race if this is the case:
 
  +sigsuspend(suspend_handler_mask);/* Wait for signal */
  +while (GC_world_is_stopped  GC_stop_count == my_stop_count) {
 
 Imagine that this thread gets a spurious signal. The 
 GC_stop_count++ statement has already taken effect, but the 
 GC_world_is_stopped = TRUE has not, the thread would bypass 
 the wait, causing the world not to be stopped.
 
 In fact, how do we know that my_stop_count is correct?
 
 When I put this in the mono tree, I'd really have something 
 with barriers in it and use the version that I suggested. 
 Without the barriers, am a bit worried about the correctness 
 (especially since the issues happen on platforms I am not 
 testing with).
 
 -- Ben
 
 
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] Re: [Mono-list] IStream implementation on Win32 for System.Drawing.Image.InitFromStream

2005-08-04 Thread Huaiyang Mao
Hello Kornél,

many thanks for your effort in implementing IStream on Win32. Do you
know when the IStream implementation on Unix available? I need the
feature to generate resource file from another resx file with image
stream. Many thanks for your help.

best regards,
Huaiyang
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Compiling from sources

2005-08-04 Thread Kornél Pál

Hi,

IP's of Mono SVN servers are blacklisted in a lot of anti-P2P lists because
they belong to Novell and they think that it's dangerous to use allow
connections to and from servers of Novell altough they are open source SVN
servers.

If you (anyone) are using such IP blockers you will be unable to connect to
Mono SVN servers.

Kornél

- Original Message -
From: Paul F. Johnson [EMAIL PROTECTED]
To: mono-devel Mono-devel-list@lists.ximian.com
Sent: Thursday, August 04, 2005 3:21 PM
Subject: RE: [Mono-devel-list] Compiling from sources



Hi,

svn is working fine from here.

TTFN

Paul
--
Some people will do anything for a woman in uniform - The Doctor -
Unregenerate (Big Finish audio)

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] C or C# and Card Reader

2005-08-04 Thread Rafael Teixeira
For security concerns (virus/trojans/etc.) normally web content isn't
allowed to interoperate with local programs. You must have things
sandboxed to prevent harm to your client system by malicious web
content.

You can approach a need like your from many angles:

-- Create browser component (a Firefox XPCOM/IE ActiveX component),
with a VERY thoughtfully SECURE design (for example requiring ssl
connection (certificate-signed) to just an specific URL to enable
gathering information from the serial) to embed in your page. This
means digitally signing packaging the component to be able to have it
trusted by the browser/system. The page javascript would possibly post
the information gathered by the component to navigate to the new page.
Commentary: A java applet would not be able to talk to the serial port
inside the browser sandboxed VM, so it isn't a choice here.

-- Invert command: Embed the HTML viewer in the client application
that conducts all the operation securely just using the viewer to show
the results.

-- Skip web content altogether: Write a good (GTK#) GUI application
for the whole issue, talking web services with the server.

Clearly mono can be used easily for the last two suggestions, but
currently isn't able to  help implement the first one.

HIH,

:)

On 8/1/05, Alf C Stockton [EMAIL PROTECTED] wrote:
 Would it be possible in a client/server environment, similar to a web
 environment, to create a program on the client that would be called from a web
 page.
 This program would read a serial connected card reader, and have that read 
 data
 passed to the server so that the server could retrieve data based on what was
 passed and return same to the client as a web page.
 
 ---
 
 Regards,
 Alf Stocktonwww.stockton.co.za
 
 Contrary to popular belief, penguins are not the salvation of modern
 technology.  Neither do they throw parties for the urban proletariat.
 
 My email disclaimer can be read at: http://www.stockton.co.za/disclaimer.html
 If you don't have web access, the disclaimer can be mailed to you on request.
 
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list
 


-- 
Rafael Monoman Teixeira
---
I'm trying to become a Rosh Gadol before my own eyes. 
See http://www.joelonsoftware.com/items/2004/12/06.html for enlightment.
It hurts!
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] [PATCH] JScript.NET code generation

2005-08-04 Thread Jb Evain

Hello there,

For the moment, mjs emits an assembly with an RequestAttribute with  
an empty blob. If this is permitted by the runtime, the attribute is  
not valid regarding to the spec. Moreover, jsc emits here an  
attribute with the version of the runtime as argument.


Here is a proposed patch, could it be reviewed ?

Jb


jscript.diff
Description: Binary data
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] fedora x86-64 packages?

2005-08-04 Thread Dan Berger




On Thu, 2005-07-28 at 01:46 +0300, Anton Andreev wrote:

  Does any body successfully compiled all mono packages on Fedora Core 4
 x86_64? I failed ... If someone did can you please recompile them in a
 directory, tar and gzip it and release it somehow? or make a rpm? I can
 host such a package. Would the Suse x86_64 rpms work on Fedora x86_64?


In the past I've struggled to get Mono built and installed on Fedora (and RH9 before that). I gave up a while back - it was sucking up too much time. 

I'm now in the same boat - running FC4 x86_64, and unable to find packages. I've installed the 32bit installer - which works, but requires installing 32bit versions of any libraries that applications I want to build (f-spot, muine, ...) depend on. It quickly becomes unmanageable.

I saw Ben's response that you can use the suse x86_64 RPMS, but that gtk-# won't work - that's not really a solution, as such.

Mono has some real value, and more and more interesting apps are being written all the time, but until getting the runtime installed on an arbitrary distro is *easy,* I suspect it's uptake will be hampered.

I've never understood is why Novell doesn't (and Ximian didn't) make working SRPMs or SPECS available that correspond with the RPMS they distribute. I'd be OK doing an rpmbuild --rebuild to get x86_64 packages, but installing without package management is just one of those things I avoid whenever possible.





--

...Dan Berger [EMAIL PROTECTED]
   http://oubliette.org/~dberger
   Inter arma silent leges
   A982 E6B1 CB2F 7A49  843A 9297 DA73 4371  1F54 8D0C

   Facts are the air of scientists. Without them you can never fly.

	 - Linus Pauling








signature.asc
Description: This is a digitally signed message part
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] Re: [Mono-list] mcs precise location patch is now in svn.

2005-08-04 Thread Ben Motmans
On 8/2/05, Atsushi Eno [EMAIL PROTECTED] wrote:
 Hello,
 
 My precise location patch for mcs (to report line/column, where it
 used to report incorrect locations) is now checked in svn.
 
 If any of you found such case that mcs does not report error location,
 please file a bug and/or report it here, with an example.
 
 Thanks,
 Atsushi Eno

using mcs r47994,
if the column is  255, it starts counting from 0 again

if you compile the attached file 'Test3.cs', you get the message
Test3.cs(6,13): warning CS0168: The variable `a' is declared but never used
while the location should be (6,255+)

it only shows '255+' when there is an error/warning at column 255

-- Ben
using System;

public class Test3 {
	public static void Main (string[] args)
	{
		int reaylngvaarnaaameethatexcedescolummmntwohundredfiftyfive; int a;
	}
}
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Re: [Mono-list] IStream implementation on Win32 for System.Drawing.Image.InitFromStream

2005-08-04 Thread Huaiyang Mao
Hello Kornél,

many thanks for your tip. 

If I use the tool of resgen in mono/libgdiplus to generate resource
file from the following resx file, I always got the exception:
Feature not implemented. This exception will be throwed from the
method of GdipLoadImageFromStream of image.cs in the libgdiplus. I am
still wondering why I got the exception.

Best regards,
Huaiyang

On 8/2/05, Kornél Pál [EMAIL PROTECTED] wrote:
 Hi Huaiyang,
 
 IStream is not requires on Unix. Mono uses lingdiplus (a GDI+-like wrapper
 library based on Cairo) that uses delegated passed to a function instead of
 an interface.
 
 Loading images from streams and saving images to streams were implemented
 for a long time for Unix when I created this wrapper for Win32 because it
 was not supported on Win32 as GDI+ requires IStream but Mono has no COM
 interop support.
 
 Kornél
 
 - Original Message -
 From: Huaiyang Mao
 Sent: Tuesday, August 02, 2005 9:45 AM
 Subject: [Mono-devel-list] Re: [Mono-list] IStream implementation on Win32
 for System.Drawing.Image.InitFromStream
 
 
 Hello Kornél,
 
 many thanks for your effort in implementing IStream on Win32. Do you
 know when the IStream implementation on Unix available? I need the
 feature to generate resource file from another resx file with image
 stream. Many thanks for your help.
 
 best regards,
 Huaiyang
 



ImageResource.resx
Description: Binary data
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] make distcheck problems / autogen.sh?

2005-08-04 Thread Paolo Molaro
On 08/04/05 IT2003_1: Morenz, Tino wrote:
 At least I got a clue where my problems come from.
 However I do _not_ have a autogen.sh. (I use the mono-1.1.8.1 package)

autogen.sh is available in the svn module: it's not distributed in the
tarball, likely because the tarball is supposed to be built with
./configure; make; make install.

 Atm I just patched configure itself just to see what happens next. 
 I know that this is a very bad solution and I'll fix it.
 However it would be nice to know what autogen script does exactly.

If you're planning to do mono hacking, I suggest getting the mono
and mcs modules from the svn server and building them after having
installed the last released mono tarball.

lupus

-- 
-
[EMAIL PROTECTED] debian/rules
[EMAIL PROTECTED] Monkeys do it better
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] [PATCH] to support '.permissionset' in ilasm

2005-08-04 Thread Ankit Jain
Hi,

Attached are two patches for ilasm and peapi for supporting
'.permissionset' in ilasm. If somebody can provide testcases for
'.permission' then maybe i can implement that too.

The patches are also attached with this bug report :
http://bugzilla.ximian.com/show_bug.cgi?id=66033.

Please review.

Regards,
Ankit

-- 
Blog :
Mono hacking : http://mono-nosip.blogspot.com
Personal : http://www.corewars.org/radical
Index: ilasm/codegen/DeclSecurity.cs
===
--- ilasm/codegen/DeclSecurity.cs	(revision 0)
+++ ilasm/codegen/DeclSecurity.cs	(revision 0)
@@ -0,0 +1,38 @@
+//
+// Mono.ILASM.DeclSecurity
+//
+// Author(s):
+//  Ankit Jain  [EMAIL PROTECTED]
+//
+// (C) 2005 Ankit Jain, All rights reserved
+//
+
+
+using System;
+using System.Collections;
+
+namespace Mono.ILASM {
+
+public interface IDeclSecurityTarget {
+void AddDeclSecurity (DeclSecurity declsecurity);
+}
+
+public class DeclSecurity {
+
+		private PEAPI.SecurityAction sec_action;
+		private byte[] data;
+
+		public DeclSecurity (PEAPI.SecurityAction sec_action, byte [] data)
+{
+			this.sec_action = sec_action;
+this.data = data;
+}
+
+public void AddTo (CodeGen code_gen, PEAPI.MetaDataElement elem)
+{
+code_gen.PEFile.AddDeclSecurity (sec_action, data, elem);
+}
+
+}
+
+}
Index: ilasm/codegen/TypeDef.cs
===
--- ilasm/codegen/TypeDef.cs	(revision 47904)
+++ ilasm/codegen/TypeDef.cs	(working copy)
@@ -13,7 +13,7 @@
 
 namespace Mono.ILASM {
 
-public class TypeDef : ICustomAttrTarget {
+public class TypeDef : ICustomAttrTarget, IDeclSecurityTarget {
 
 protected class GenericInfo {
 public string Id;
@@ -32,6 +32,7 @@
 private ArrayList field_list;
 private Hashtable method_table;
 private ArrayList customattr_list;
+private ArrayList declsecurity_list;
 private ArrayList event_list;
 private ArrayList property_list;
 private ArrayList typar_list;
@@ -212,6 +213,14 @@
 customattr_list.Add (customattr);
 }
 
+public void AddDeclSecurity (DeclSecurity declsecurity)
+{
+if (declsecurity_list == null)
+declsecurity_list = new ArrayList ();
+
+declsecurity_list.Add (declsecurity);
+}
+
 public void AddGenericParam (string id)
 {
 if (typar_list == null)
@@ -355,7 +364,15 @@
 foreach (CustomAttr customattr in customattr_list)
 customattr.AddTo (code_gen, classdef);
 }
+
+/// Add declarative security to this method
+if (declsecurity_list != null) {
+foreach (DeclSecurity declsecurity in declsecurity_list)
+declsecurity.AddTo (code_gen, classdef);
 
+classdef.AddAttribute (PEAPI.TypeAttr.HasSecurity);
+			}	
+
 if (override_list != null) {
 foreach (DictionaryEntry entry in override_list) {
 MethodDef body = (MethodDef) entry.Key;
Index: ilasm/codegen/ChangeLog
===
--- ilasm/codegen/ChangeLog	(revision 47940)
+++ ilasm/codegen/ChangeLog	(working copy)
@@ -1,3 +1,20 @@
+2005-08-04  Ankit Jain  [EMAIL PROTECTED]
+
+	* DeclSecurity.cs: New File.
+	  (DeclSecurity): New class.
+	  (IDeclSecurityTarget): New interface.
+	* TypeDef.cs (TypeDef): Implement IDeclSecurityTarget.
+	  (TypeDef.DefineContents): Add DeclSecurity info.
+	* CodeGen.cs (CurrentDeclSecurityTarget): New. Property for current
+	  DeclSecurity target.
+	  (BeginTypeDef, BeginMethodDef, BeginAssemblyRef): Set current DeclSecurity
+	  target accordingly.
+	  (AddAssemblyDeclSecurity): New. Add DeclSecurity info to assembly.
+	* ExternTable.cs (ExternAssembly): Implement IDeclSecurityTarget.
+	  (Resolve): Add DeclSecurity info to AssemblyRef.
+	* MethodDef.cs (MethodDef): Implement IDeclSecurityTarget.
+	  (WriteCode): Add DeclSecurity info to MethodDef.
+
 2005-08-03  Ankit Jain  [EMAIL PROTECTED]
 
 	* GlobalMethodRef.cs (GlobalMethodRef.Resolve): Use CreateVarargSignature
Index: ilasm/codegen/CodeGen.cs
===
--- ilasm/codegen/CodeGen.cs	(revision 47904)
+++ ilasm/codegen/CodeGen.cs	(working copy)
@@ -33,6 +33,7 @@
 		

Re: [Mono-devel-list] [PATCH] Check for assembly attributes

2005-08-04 Thread Ben Maurer
On Thu, 2005-08-04 at 00:07 -0500, Carlos Alberto Cortez wrote:
  This precludes us from using the assembly in mscorlib.dll. It could
  potentially be useful to use there -- say to let us write nunit tests
  that poked at internals.
 
 I'm not very sure about the scenarios you are thinking in. Could you
 please show some detailed examples?

For example, I add an internal api to corlib called FooParser. I want to
write nunit tests, so what I do is make the nunit assembly be able to
see corlib's insides.

  
  See http://blogs.msdn.com/junfeng/archive/2004/09/14/229254.aspx about
  how there is support for handling commas in file names. Your code would
  break under this.
 
 Well, I didn't know about that, but IHMO I find it like a very bad
 practice, and I'm sure that there aren't people out there who like to
 call their assemblies 'My,Assembly,Version=xx... or something like
 that.

Well, it was important enough to add the feature in msft

 Also, to test this, I tried to load an assembly named
 'Test,Assembly' (using Assembly.Load ()) in both mono and ..NET, and
 neither could load it successfully. The only way to work with it AFAIK
 is when you get name of the assembly itself, or use Assembly.LoadFrom.

It is a whidbey feature, as mentioned in the article.

-- Ben

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


RE: [Mono-devel-list] Graphics merge-in status

2005-08-04 Thread Andrew Skiba
I commited this helper. It is possible to compile and run it under Mono,
but I did not make generate and test phases yet. I'll continue to work
on it on Sunday. Anyway, code is available to play with, and there are
basic Makefiles to build and run it.

 The next thing I want to do is to commit the drawing tests 
 helper we started to develop at Mainsoft.
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Re: [Mono-list] IStream implementation on Win32for System.Drawing.Image.InitFromStream

2005-08-04 Thread Peter Dennis Bartok
 If I use the tool of resgen in mono/libgdiplus to generate resource
 file from the following resx file, I always got the exception:
 Feature not implemented. This exception will be throwed from the
 method of GdipLoadImageFromStream of image.cs in the libgdiplus. I am
 still wondering why I got the exception.

Because your libgdiplus library is apparently been compiled without support 
for the particular type of image you're trying to open. At the end of 
configure it will tell you format libs it found (and where to get them if it 
didn't find them)

Peter 

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] ThreadAbortException - Why is it rethrown?

2005-08-04 Thread David Waite
ThreadAbort is thrown as result of the thread being aborted. You
cannot unabort the thread, just do cleanup before it finishes. So when
you catch the ThreadAbort, it is rethrown automatically to go to the
next higher cleanup routine.

-David Waite

On 8/4/05, Vivek, Bharath Varma (IE10) [EMAIL PROTECTED] wrote:
 Hi,
 
 I have a question regarding ThreadAbortException.
 Why is the thread abort exception rethrown at the end of a catch clause?
 Why is ThreadAbortException's behavior designed to be this way?
 
 Thanks in advance
 -Vivek
 
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] Re: [Mono-list] mcs precise location patch is now in svn.

2005-08-04 Thread Atsushi Eno
Hi,

 using mcs r47994,
 if the column is  255, it starts counting from 0 again
 
 if you compile the attached file 'Test3.cs', you get the message
 Test3.cs(6,13): warning CS0168: The variable `a' is declared but never used
 while the location should be (6,255+)
 
 it only shows '255+' when there is an error/warning at column 255

Oh, true... so I fixed this bug in svn (r48002).

Thanks,
Atsushi Eno
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] Re: [Mono-list] mcs precise location patch is now in svn.

2005-08-04 Thread Atsushi Eno
Hi,

 using mcs r47994,
 if the column is  255, it starts counting from 0 again
 
 if you compile the attached file 'Test3.cs', you get the message
 Test3.cs(6,13): warning CS0168: The variable `a' is declared but never used
 while the location should be (6,255+)
 
 it only shows '255+' when there is an error/warning at column 255

Oh, true... so I fixed this bug in svn (r48002).

BTW, yes, it is a limitation of location reporting that the maximum
precise column number is 255 (to save memory consumption).

Thanks,
Atsushi Eno
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Edit and Continue

2005-08-04 Thread David Srbecky
Thanks for the reply,

Some people at Microsoft were very kind and have send me their, at the
moment, internal Edit and Continue documentation. I will not repay their
kindness by publishing these documents on public maillist, but if anyone
is interested please let me know and I will send the documentation to you.

ILAsm v2.0 is able to produce metadata deltas which we can use to
further check the implementation.

I have written a debugging library that uses MS debugging API and which
can apply metadata and il deltas to running programs. (So far, it was
successfully test on the output of ildasm)

Thanks for help,

David

Paolo Molaro wrote:
 On 08/03/05 David Srbecky wrote:
 
My name is David Srbecky and I am working on SharpDevelop 2.0 debugger.
The debugger is getting nearly finished, but it is still missing one
'cool' feature - edit and continue. The support for Edit and Continue
(EnC) from the side of Microsoft runtime is good enough, but there is no
support at all from the compiler side - all the functionality is private
and mostly part of VS. This effectively means that to support EnC, I
must write my own compiler. I would never try to that, but fortunately
there is mono to save the day. I would like to use the mono compiler to
produce the necessary deltas, which I must feed to MS runtime. The
problem is the I know neither the internals of mono compiler nor the
internals of System.Reflection.Emit and implementing support of EnC
would be a tedious or impossible task for me.
 
 
 There is no documentation about what the MS runtime expects in the
 edit and continue metadata tables. You could get someone living in a
 free country to reverse engineer the metadata tables and write a spec.
 Then we could start to see if the spec is easily implementable in
 mono's reflection.emit code.
 My guess is that it would be quite complex to implement _and_ make
 it work with the MS runtime.
 
 If people find the editcontinue feature useful, I suggest
 implementing it in mono for mono (this of course requires people to
 help the debugger folks first, though).
 
 lupus
 
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Error Building

2005-08-04 Thread Paolo Molaro
On 08/03/05 Jonathan S. Chambers wrote:
 Thanks Paul. Unfortunately, that's what I'm going by :-(
 
 A few others have emailed me to say they have the same problem.

Until people don't report the issue, they won't get fixed.
The easy way to compile from svn is to first install
a recent released mono tarball. If you have already messed up
your mcs module, you migh need to rm -rf mcs/class/lib and svn update
the mcs module again. Then, just run autogen.sh in mono/ and
use the usual ./configure; make; make install.

If this fails, we need people to provide a useful error message,
which you'd get by compiling a sample C# program with mcs in your case.

lupus

-- 
-
[EMAIL PROTECTED] debian/rules
[EMAIL PROTECTED] Monkeys do it better
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Too many heap sections: Increase MAXHINCR or MAX_HEAP_SECTS

2005-08-04 Thread Paolo Molaro
On 08/02/05 Joannes Vermorel wrote:
 I am currently developping a scientific computing application in C#.
 Basically, the application is simple, first it loads from a text file
 roughly 100MB of data, and then run a CPU intensive algorithm. The memory
 required while running the algo is around 600MB. I am not using anything
 beyond the System.Collections in .Net.
 
 On MS .Net 1.1, the computation works well and terminates properly. On a
 linux AMD64 (with 8GO of memory), the program is aborded at mid-computation
 and the only message that I get is
 
 Too many heap sections: Increase MAXHINCR or MAX_HEAP_SECTS
 
 (I am using mono 1.1.8, compiled with the option --with-large-heap=yes).

Could you provide the code and the data? If not you'll have to
debug the issue yourself. Try setting the GC_PRINT_STATS or
GC_DUMP_REGULARLY environment vars and see if the GC heap
gets fragmented or if it increases too much.
What kind of collections do you use? Do you allocate many small
objects?

lupus

-- 
-
[EMAIL PROTECTED] debian/rules
[EMAIL PROTECTED] Monkeys do it better
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Edit and Continue

2005-08-04 Thread Atsushi Eno

Hello,

David Srbecky wrote:

Thanks for the reply,

Some people at Microsoft were very kind and have send me their, at the
moment, internal Edit and Continue documentation. I will not repay their
kindness by publishing these documents on public maillist, but if anyone
is interested please let me know and I will send the documentation to you.


Even IF you are granted to distribute the copy of the Microsoft
(maybe nonpublic?) documentation from Microsoft guys (who really can
give the permission to you), it is not a good idea to scatter it.
Note that there is no legal difference if you send copyrighted
materials one by one, or just post to mass mailing lists.

Atsushi Eno
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] ThreadAbortException - Why is it rethrown?

2005-08-04 Thread Atsushi Eno

Hi,

Well, there is ResetAbort() which can stop the ThreadAbortException
only from inside the same thread (AFAIK). Other than that yes it is
not possible to stop this error propagation.

Atsushi Eno

David Waite wrote:

ThreadAbort is thrown as result of the thread being aborted. You
cannot unabort the thread, just do cleanup before it finishes. So when
you catch the ThreadAbort, it is rethrown automatically to go to the
next higher cleanup routine.

-David Waite

On 8/4/05, Vivek, Bharath Varma (IE10) [EMAIL PROTECTED] wrote:


Hi,

I have a question regarding ThreadAbortException.
Why is the thread abort exception rethrown at the end of a catch clause?
Why is ThreadAbortException's behavior designed to be this way?

Thanks in advance
-Vivek

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list



___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list



___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Edit and Continue

2005-08-04 Thread David Srbecky
 Even IF you are granted to distribute the copy of the Microsoft
 (maybe nonpublic?) documentation from Microsoft guys (who really can
 give the permission to you), it is not a good idea to scatter it.
 Note that there is no legal difference if you send copyrighted
 materials one by one, or just post to mass mailing lists.
 

I am sorry I do not understand, what is the problem? Do you suggest that
I send the documents to the maillist or do you suggest that I keep them
completely private and let people reverse engineer the format?

Mind that these are just drafts of public file specification.

David Srbecky
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-devel-list] Initial ARM JIT port in svn

2005-08-04 Thread Paolo Molaro
Hi.
People may be interested to know that the initial pass at the
JIT port to ARM is in svn.
make test in mono/tests reports 123 pass, 70 fail.
Most of the regression tests in mini/ work as well.

The missing stuff is related to stack walks (so exceptions
don't work yet, as well as some reflection features) and
some specialized opcodes. Of course, when mcs will run I'm sure
more bugs will emerge.

I only tested on my ARM box, running Debian, on an xscale
processor (v5), in little endian mode, FPA floating point format.
At this time I'm interested about compilation issues on
different systems (like with older processor versions, v4 and newer).
Also, if anyone has a big endian ARM system I would be interested in
bug reports.
Soft-float support is planned only for later (and you may speedup
the process by doing the support yourself or providing me a tarball
of a complete system compiled with soft-float).

You will need to copy mscorlib.dll, System.dll etc
and the test programs from another box and install them manually.

Thanks.

lupus

-- 
-
[EMAIL PROTECTED] debian/rules
[EMAIL PROTECTED] Monkeys do it better
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] [PATCH] JScript.NET code generation

2005-08-04 Thread Jb Evain

Hola Cesar!

Sure, here it is.

Jb



jscript.patch
Description: Binary data


On Aug 4, 2005, at 9:27 PM, César Lopéz Natarén wrote:


Hello Jb!

I like the second patch, just one thing,

+   private static string CORLIB = mscorlib,
Version=1.0.5000.0, Culture=neutral, Pub +
+   licKeyToken=b77a5c561934e089;

Could you make the loading of that info automatic, meaning that gets
extracted from the mscorlib assembly.

césar




___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Initial ARM JIT port in svn

2005-08-04 Thread Hugo Ferreira
Does this mean Mono for PocketPC is getting closer? :D

On 8/4/05, Paolo Molaro [EMAIL PROTECTED] wrote:
 Hi.
 People may be interested to know that the initial pass at the
 JIT port to ARM is in svn.
 make test in mono/tests reports 123 pass, 70 fail.
 Most of the regression tests in mini/ work as well.
 
 The missing stuff is related to stack walks (so exceptions
 don't work yet, as well as some reflection features) and
 some specialized opcodes. Of course, when mcs will run I'm sure
 more bugs will emerge.
 
 I only tested on my ARM box, running Debian, on an xscale
 processor (v5), in little endian mode, FPA floating point format.
 At this time I'm interested about compilation issues on
 different systems (like with older processor versions, v4 and newer).
 Also, if anyone has a big endian ARM system I would be interested in
 bug reports.
 Soft-float support is planned only for later (and you may speedup
 the process by doing the support yourself or providing me a tarball
 of a complete system compiled with soft-float).
 
 You will need to copy mscorlib.dll, System.dll etc
 and the test programs from another box and install them manually.
 
 Thanks.
 
 lupus
 
 --
 -
 [EMAIL PROTECTED] debian/rules
 [EMAIL PROTECTED] Monkeys do it better
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list
 



-- 
GPG Fingerprint: B0D7 1249 447D F5BB 22C5  5B9B 078C 2615 504B 7B85
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Initial ARM JIT port in svn

2005-08-04 Thread Rafael Teixeira
Perfect timing Lupus, 

I may be able to use C# instead of Java in a new embedded project.

My Heartily Thanks,

On 8/4/05, Paolo Molaro [EMAIL PROTECTED] wrote:
 Hi.
 People may be interested to know that the initial pass at the
 JIT port to ARM is in svn.
 make test in mono/tests reports 123 pass, 70 fail.
 Most of the regression tests in mini/ work as well.
 
 The missing stuff is related to stack walks (so exceptions
 don't work yet, as well as some reflection features) and
 some specialized opcodes. Of course, when mcs will run I'm sure
 more bugs will emerge.
 
 I only tested on my ARM box, running Debian, on an xscale
 processor (v5), in little endian mode, FPA floating point format.
 At this time I'm interested about compilation issues on
 different systems (like with older processor versions, v4 and newer).
 Also, if anyone has a big endian ARM system I would be interested in
 bug reports.
 Soft-float support is planned only for later (and you may speedup
 the process by doing the support yourself or providing me a tarball
 of a complete system compiled with soft-float).
 
 You will need to copy mscorlib.dll, System.dll etc
 and the test programs from another box and install them manually.
 
 Thanks.
 
 lupus
 
 --
 -
 [EMAIL PROTECTED] debian/rules
 [EMAIL PROTECTED] Monkeys do it better
 ___
 Mono-devel-list mailing list
 Mono-devel-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-devel-list
 


-- 
Rafael Monoman Teixeira
---
I'm trying to become a Rosh Gadol before my own eyes. 
See http://www.joelonsoftware.com/items/2004/12/06.html for enlightment.
It hurts!
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] [PATCH] Check for assembly attributes

2005-08-04 Thread Ben Maurer
On Thu, 2005-08-04 at 17:15 -0500, Carlos Alberto Cortez wrote:
 +   if (String.CompareOrdinal
 (values [0], Version) == 0)
 +   version = true;

Weren't these case insensitive in your first version?

If they are, then you can just use String.Equals, otherwise, i think
this call is wrong

-- Ben

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] [PATCH] Check for assembly attributes

2005-08-04 Thread Carlos Alberto Cortez
Right, that's true, since we need to support an insensitive case
comparison. Just corrected that.

Carlos.

El jue, 04-08-2005 a las 18:23 -0400, Ben Maurer escribió:
 On Thu, 2005-08-04 at 17:15 -0500, Carlos Alberto Cortez wrote:
  +   if (String.CompareOrdinal
  (values [0], Version) == 0)
  +   version = true;
 
 Weren't these case insensitive in your first version?
 
 If they are, then you can just use String.Equals, otherwise, i think
 this call is wrong
 
 -- Ben
 

___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-devel-list] Error Building

2005-08-04 Thread Peter Dennis Bartok
You need mcs to build mcs since it's written in c# :-) That's why you need a 
tarball or similar to get a working mcs.exe.

./configure checks the capabilities of the particular unix version you are 
running on, to figure out the proper compiler switches, include files, 
features, etc, that your system supports.

the configure script is generated when you run autogen.sh.

You could try 'make get-monolite-latest' to get a working mcs to bootstrap 
your build (see the mono README)

Cheers,
 Peter


-Original Message-
From: Jonathan S. Chambers [EMAIL PROTECTED]
To: Paolo Molaro [EMAIL PROTECTED]; mono-devel-list@lists.ximian.com
Date: 04 August, 2005 19:20
Subject: RE: [Mono-devel-list] Error Building


I'm a bit confused. According to Paul's site, the first thing to do is to 
completely remove mono from your system (didn't really apply to me since the 
machine was clean). Are you saying I should install a mono tarball? Do I 
then remove it later?

Also, as a newbie, what does the ./configure do?

Thanks,
Jonathan


-Original Message-
From: [EMAIL PROTECTED] on behalf of Paolo Molaro
Sent: Thu 8/4/2005 9:56 AM
To: mono-devel-list@lists.ximian.com
Cc:
Subject: Re: [Mono-devel-list] Error Building
On 08/03/05 Jonathan S. Chambers wrote:
 Thanks Paul. Unfortunately, that's what I'm going by :-(

 A few others have emailed me to say they have the same problem.

Until people don't report the issue, they won't get fixed.
The easy way to compile from svn is to first install
a recent released mono tarball. If you have already messed up
your mcs module, you migh need to rm -rf mcs/class/lib and svn update
the mcs module again. Then, just run autogen.sh in mono/ and
use the usual ./configure; make; make install.

If this fails, we need people to provide a useful error message,
which you'd get by compiling a sample C# program with mcs in your case.

lupus

-- 
-
[EMAIL PROTECTED] debian/rules
[EMAIL PROTECTED] Monkeys do it better
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list



___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-list] Problem with Events

2005-08-04 Thread mono-list . 1 . tracyanne
Can anyone see anything wrong with this code. It looks to me to be
correct syntax for defining and raising an event. It compiles without
error, but when I run it I get the following error message


Unhandled Exception: System.NullReferenceException: Object reference not
set to an instance of an object
in [0x1] (at /home/tracy/MonoDevelop/TestEvents/Main.cs:22)
RaiseAnEvent:Run ()
in [0x7] (at /home/tracy/MonoDevelop/TestEvents/Main.cs:11)
MainClass:Main (System.String[] args)

I'm using Mono_1.1.8-2.

// project created on 04/08/2005 at 17:17
using System;

class MainClass
{

public static void Main(string[] args)
{
RaiseAnEvent RAE = new RaiseAnEvent();
RAE.Run();
}
}

class RaiseAnEvent
{
public delegate void InputError(object sender, InputErrorEventArgs e);
public event InputError OnInputError;

public void Run()
{
OnInputError(this, new InputErrorEventArgs(DF, OI));
}

}


//Class for passing Input Error messages to the application
class InputErrorEventArgs : EventArgs
{
private string errorMessage;
private string errorSource;

public string ErrorMessage
{
get
{
return errorMessage;
}
}

public string ErrorSource
{
get
{
return errorSource;
}
}

public InputErrorEventArgs(string Message, string Source) : base()
{
errorMessage = Message;
errorSource = Source;
}
}
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Problem with Events

2005-08-04 Thread Jackson Harper
On Thu, 2005-08-04 at 17:30 +1000, [EMAIL PROTECTED]
wrote:
 Can anyone see anything wrong with this code. It looks to me to be
 correct syntax for defining and raising an event. It compiles without
 error, but when I run it I get the following error message

Nothing is ever subscribing to your event, so it is null when you are
trying to invoke it. You need something like:

OnInputError += new InputError (ErrorHandlerFunction); somewhere.

A few general style comments:

1. Normally event handler delegates are named somethingHandler. So
your InputError delegate would be named InputErrorHandler.

2. Normally events names don't start with On. So OnInputError would be
InputError.

3. It's common to wrap the instantiation of an event in a protected
method named OnEvent Name. So you would have a method that looks like
this:

protected void OnInputError (InputErrorEventArgs e)
{
if (InputError != null)
InputError (this, e);
}


Cheers,
Jackson


 
 Unhandled Exception: System.NullReferenceException: Object reference not
 set to an instance of an object
 in [0x1] (at /home/tracy/MonoDevelop/TestEvents/Main.cs:22)
 RaiseAnEvent:Run ()
 in [0x7] (at /home/tracy/MonoDevelop/TestEvents/Main.cs:11)
 MainClass:Main (System.String[] args)
 
 I'm using Mono_1.1.8-2.
 
 // project created on 04/08/2005 at 17:17
 using System;
 
 class MainClass
 {
   
   public static void Main(string[] args)
   {
   RaiseAnEvent RAE = new RaiseAnEvent();
   RAE.Run();
   }
 }
 
 class RaiseAnEvent
 {
   public delegate void InputError(object sender, InputErrorEventArgs e);
   public event InputError OnInputError;
   
   public void Run()
   {
   OnInputError(this, new InputErrorEventArgs(DF, OI));
   }
 
 }
 
   
 //Class for passing Input Error messages to the application
 class InputErrorEventArgs : EventArgs
 {
   private string errorMessage;
   private string errorSource;
   
   public string ErrorMessage
   {
   get
   {
   return errorMessage;
   }
   }
   
   public string ErrorSource
   {
   get
   {
   return errorSource;
   }
   }
   
   public InputErrorEventArgs(string Message, string Source) : base()
   {
   errorMessage = Message;
   errorSource = Source;
   }
 }
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] mcs precise location patch is now in svn.

2005-08-04 Thread Ben Motmans
On 8/2/05, Atsushi Eno [EMAIL PROTECTED] wrote:
 Hello,
 
 My precise location patch for mcs (to report line/column, where it
 used to report incorrect locations) is now checked in svn.
 
 If any of you found such case that mcs does not report error location,
 please file a bug and/or report it here, with an example.
 
 Thanks,
 Atsushi Eno

using mcs r47994,
if the column is  255, it starts counting from 0 again

if you compile the attached file 'Test3.cs', you get the message
Test3.cs(6,13): warning CS0168: The variable `a' is declared but never used
while the location should be (6,255+)

it only shows '255+' when there is an error/warning at column 255

-- Ben
using System;

public class Test3 {
	public static void Main (string[] args)
	{
		int reaylngvaarnaaameethatexcedescolummmntwohundredfiftyfive; int a;
	}
}
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] ByteFX remote clients

2005-08-04 Thread Tom Larsen
Unfortunately there could be any number of reasons why the other
machine is not reachable.  Without more information there is little I
can suggest.  I would try making a very simple program that just does a
simple select on a table and work through the software configuration on
both machines until it works.

Tom Larsen

On Wed, 2005-08-03 at 23:06, Tarun R wrote:
 I use ByteFX.Data.MySqlClient to access MySQL databases.
 When I use the Database at the localhost, it works fine.
 When I use the database on a remote server, there is an error which
 says it can't be opened, even if it is the ip of the localhost.
 I use mono-1.1.8-2.
 
 Help. Thanks.
 
 
 __
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list
-- 
Tom Larsen [EMAIL PROTECTED]

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Add/Remove users

2005-08-04 Thread Arx Henrique
Is possible create/remove/edit linux users with mono?


-- 
A fé remove montanas, mas eu prefiro a dinamite
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Mono, Win32 fibers. Almost there...

2005-08-04 Thread Paolo Molaro
On 08/03/05 Bruce Wilkie wrote:
 One final question in hopes someone has an idea.  I've
 gotten fibers to work with both the JIT and Interp

Nice. You can ignore the interp, since we don't maintain it anymore.

 engines.  However, I'm having problems with garbage
 collection.  That is, objects seem to be getting
 collected when the shouldn't.
 
 Could it be because the stack of the fiber isn't
 registered with the boehm collector?  does that sound
 right?

Yes, that's very likely. How do you allocate those stacks?
You're supposed to use GC_MALLOC (stack_size). If you can't
allocate them yourself, you'll have to change the GC code
so that it knows about the stacks and use GC_push_all_stack ().
See the libgc code for examples of when and how to call it.

lupus

-- 
-
[EMAIL PROTECTED] debian/rules
[EMAIL PROTECTED] Monkeys do it better
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Sqlite version

2005-08-04 Thread Julien Sobrier

Hello,
do you know what Sqlite version is handled by Mono.Data.SqliteClient.dll 
in Mono 1.1.6: 1, 2 or 3?


Thank you
Julien
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] mcs precise location patch is now in svn.

2005-08-04 Thread Atsushi Eno
Hi,

 using mcs r47994,
 if the column is  255, it starts counting from 0 again
 
 if you compile the attached file 'Test3.cs', you get the message
 Test3.cs(6,13): warning CS0168: The variable `a' is declared but never used
 while the location should be (6,255+)
 
 it only shows '255+' when there is an error/warning at column 255

Oh, true... so I fixed this bug in svn (r48002).

Thanks,
Atsushi Eno
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] mcs precise location patch is now in svn.

2005-08-04 Thread Atsushi Eno
Hi,

 using mcs r47994,
 if the column is  255, it starts counting from 0 again
 
 if you compile the attached file 'Test3.cs', you get the message
 Test3.cs(6,13): warning CS0168: The variable `a' is declared but never used
 while the location should be (6,255+)
 
 it only shows '255+' when there is an error/warning at column 255

Oh, true... so I fixed this bug in svn (r48002).

BTW, yes, it is a limitation of location reporting that the maximum
precise column number is 255 (to save memory consumption).

Thanks,
Atsushi Eno
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] RE: System.Security.Cryptography/CryptographicUnexpectedOperationExcpetion .cs

2005-08-04 Thread cliff
I think I figured it out. For some reason, the latest mono archive doesn't
fully restore using 7zip (I downloaded it again to verify), although it
'tests' fine. Also, the file mentioned below is in CVS (I was looking in
wrong folder).

Cliff
--
 Hello,
 I get the following error when trying to build mono from scratch, with
 latest source package (not cvs sync):
 make[7]: Entering directory
 `/home/cap/mono/mono/mono-1.1.8/mcs/class/corlib'
 Creating ../../build/deps/basic_corlib_res.dll.response ...
 Creating ../../build/deps/basic_corlib_res.dll.makefrag ...
 Creating ../../build/deps/basic_corlib.dll.makefrag ...
 make[7]: Leaving directory
`/home/cap/mono/mono/mono-1.1.8/mcs/class/corlib'
 make[7]: Entering directory
 `/home/cap/mono/mono/mono-1.1.8/mcs/class/corlib'
 make all-local
 make[8]: Entering directory
 `/home/cap/mono/mono/mono-1.1.8/mcs/class/corlib'
 make[8]: *** No rule to make target
 `System.Security.Cryptography/CryptographicUnexpectedOperationExcpetion.cs',
needed by `../../class/lib/basic/mscorlib.dll'.  Stop.
 I may be mistaken, but it appears that this file is missing. I check CVS,
not there either.
 Thanks,
 Cliff


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Npgsql error

2005-08-04 Thread Fabian Salamanca Dominguez
Hi

I tried to compile a simple C# program and access a Postgresql DB but I got this error in runtime (it compiled with no errors) :

[EMAIL PROTECTED] Mono]$ mcs dbaccess.cs -r:Npgsql.dll -r:System.Data.dll
[EMAIL PROTECTED] Mono]$ mono dbaccess.exe

Unhandled Exception: System.InvalidCastException: Cannot cast from source type to destination type.
in 0x000e1 dbAccess:Main (System.String[] args)



This is the code:

using System;
using System.Data;
using Npgsql;
public class dbAccess
{
 public static void Main(string[] args)
 {
 string connectionString =
 Server=localhost; +
 Database=opennms; +
 User ID=opennms; +
 Password=opennms;;
 IDbConnection dbcon;
 dbcon = new NpgsqlConnection(connectionString);
 dbcon.Open();
 IDbCommand dbcmd = dbcon.CreateCommand();
 string sql =
 SELECT operatingsystem, nodeid  +
 FROM assets;
 dbcmd.CommandText = sql;
 IDataReader reader = dbcmd.ExecuteReader();
 while(reader.Read()) {
 string operatingsystem = (string) reader[operatingsystem];
 string nodeid = (string) reader[nodeid];
 Console.WriteLine(OS:  +

operatingsystem +   + nodeid);
 }
 // clean up
 reader.Close();
 reader = null;
 dbcmd.Dispose();
 dbcmd = null;
 dbcon.Close();
 dbcon = null;
 }
}

What am I doing wrong?

Thanks!!!-- Fabian
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Npgsql error

2005-08-04 Thread Emil Emilov

Check the lines:
string operatingsystem = (string) reader[operatingsystem];
string nodeid = (string) reader[nodeid];

What happens of the results are NULL?
You should check for NULL first.

Then, are you sure that operatingsystem and nodeid are varchars or some other 
type that translate into string?
If not then you would get that exception.

Cheers,
Emil

Fabian Salamanca Dominguez wrote:


Hi

I tried to compile a simple C# program and access a Postgresql DB but I 
got this error in runtime (it compiled with no errors) :


[EMAIL PROTECTED] Mono]$ mcs dbaccess.cs  -r:Npgsql.dll -r:System.Data.dll
[EMAIL PROTECTED] Mono]$ mono dbaccess.exe

Unhandled Exception: System.InvalidCastException: Cannot cast from 
source type to destination type.

in 0x000e1 dbAccess:Main (System.String[] args)



This is the code:

using System;
using System.Data;
using Npgsql;
public class dbAccess
 {
public static void Main(string[] args)
{
   string connectionString =
  Server=localhost; +
  Database=opennms; +
  User ID=opennms; +
  Password=opennms;;
   IDbConnection dbcon;
   dbcon = new NpgsqlConnection(connectionString);
   dbcon.Open();
   IDbCommand dbcmd = dbcon.CreateCommand();
   string sql =
   SELECT operatingsystem, nodeid  +
   FROM assets;
   dbcmd.CommandText = sql;
   IDataReader reader = dbcmd.ExecuteReader();
   while(reader.Read()) {
string operatingsystem = (string) reader[operatingsystem];
string nodeid = (string) reader[nodeid];
Console.WriteLine(OS:  +
 operatingsystem +   + nodeid);
   }
   // clean up
   reader.Close();
   reader = null;
   dbcmd.Dispose();
   dbcmd = null;
   dbcon.Close();
   dbcon = null;
}
 }

What am I doing wrong?

Thanks!!!
--
Fabian




___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


--
Emil R. Emilov
---
mailto:[EMAIL PROTECTED]
http://www.emilov.de
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Problems running monodevelop (svn) and muine (svn)

2005-08-04 Thread Pieter Baele
Everything builds fine. I am using latest mono (1.1.8.2) in gentoo and
gtk-sharp 2.5.5

Apps running fine: latest f-spot and tomboy
Can someone figure this out?



Trying to start monodevelop:


Unhandled Exception: System.TypeInitializationException: An exception
was thrown by the type initializer for
MonoDevelop.Gui.Dialogs.SplashScreenForm ---
System.TypeInitializationException: An exception was thrown by the type
initializer for Gtk.Container --- System.EntryPointNotFoundException:
gtksharp_gtk_container_get_focus_child_offset
in (wrapper managed-to-native)
Gtk.Container:gtksharp_gtk_container_get_focus_child_offset ()
in 0xa Gtk.Container:.cctor ()--- End of inner exception stack
trace ---

in 0x0 unknown method
in 0xe Gtk.Bin:.ctor (IntPtr raw)
in 0x0002f Gtk.Window:.ctor (WindowType type)
in 0x00025 MonoDevelop.Gui.Dialogs.SplashScreenForm:.ctor ()
in 0x00016 MonoDevelop.Gui.Dialogs.SplashScreenForm:.cctor ()--- End
of inner exception stack trace ---

in 0x0 unknown method
in 0x005ac MonoDevelop.SharpDevelopMain:Main (System.String[] args)






With muine, i've the following error:


(muine:1832): GLib-GObject-CRITICAL **: g_object_get_data: assertion
`G_IS_OBJECT (object)' failed

... [cut]

(muine:1832): GLib-GObject-CRITICAL **: g_object_set_data: assertion
`G_IS_OBJECT (object)' failed

Unhandled Exception: System.Reflection.TargetInvocationException:
Exception has been thrown by the target of an invocation. ---
System.TypeInitializationException: An exception was thrown by the type
initializer for Gtk.Dialog --- System.EntryPointNotFoundException:
gtksharp_gtk_dialog_get_vbox_offset
in (wrapper managed-to-native)
Gtk.Dialog:gtksharp_gtk_dialog_get_vbox_offset ()
in 0x8 Gtk.Dialog:.cctor ()--- End of inner exception stack trace
---

in 0x0 unknown method
in (wrapper managed-to-native)
System.Reflection.MonoCMethod:InternalInvoke (object,object[])
in 0x0006f System.Reflection.MonoCMethod:Invoke (System.Object obj,
BindingFlags invokeAttr, System.Reflection.Binder binder,
System.Object[] parameters, System.Globalization.CultureInfo culture)---
End of inner exception stack trace ---

in 0x00104 System.Reflection.MonoCMethod:Invoke (System.Object obj,
BindingFlags invokeAttr, System.Reflection.Binder binder,
System.Object[] parameters, System.Globalization.CultureInfo culture)
in 0x00019 System.Reflection.MonoCMethod:Invoke (BindingFlags
invokeAttr, System.Reflection.Binder binder, System.Object[] parameters,
System.Globalization.CultureInfo culture)
in 0x001d7 System.Activator:CreateInstance (System.Type type,
BindingFlags bindingAttr, System.Reflection.Binder binder,
System.Object[] args, System.Globalization.CultureInfo culture,
System.Object[] activationAttributes)
in 0x00029 System.Activator:CreateInstance (System.Type type,
BindingFlags bindingAttr, System.Reflection.Binder binder,
System.Object[] args, System.Globalization.CultureInfo culture)
in 0x0008f GLib.ObjectManager:CreateObject (IntPtr raw)
in 0x000c9 GLib.Object:GetObject (IntPtr o, Boolean owned_ref)
in 0xc GLib.Object:GetObject (IntPtr o)
in 0x00045 Glade.XML:GetWidget (System.String name)
in 0x0015b Glade.XML:BindFields (System.Object target, System.Type
type)
in 0x00019 Glade.XML:BindFields (System.Object target)
in 0x00016 Glade.XML:Autoconnect (System.Object handler)
in 0x00059 Muine.ErrorDialog:.ctor (System.String s1, System.String
s2)
in 0x0001e Muine.Global:Error (System.String message)
in 0x0028c Muine.Global:Main (System.String[] args)






___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Npgsql error

2005-08-04 Thread Emil Emilov

Cool, a question on that:
What happens if a exception occurs?
I meand close() gets called at the end of the using block, but does it get also 
called when an exception occurs (sort of finally)?
If yes, I'm changing my programming style :)
Another question, how would it look like if you had to catch an exception (i.e. 
to rollback a transaction)?

Thanx :)

Jaroslaw Kowalski wrote:

Hi Emil,

Also another tip: you don't need to explicitly set connection etc. to 
null.

Cosider following improvement:

IDbConnection dbcon;
IDbCommand dbcmd;
IDataReader reader;
try {


...


} finally {
 // cleanup, even if error occurs, closing the reader is important 
because while it is open no other reader can be opened

 if (reader!=null) reader.Close();
 if (dbcmd!=null) dbcmd.Close();
 if (dbcon!=null) dbcon.Close();
}



A small tip: Your example is very java-ish. You could reduce the amount 
of code by using C# using() statement which provides automatic cleanup 
for connection, command and reader. I believe that the following is much 
more readable and saves a lot of typing:


=
using (IDbConnection c = new NpgsqlConnection(connectionString))
{
   c.Open();
   using (IDbCommand cmd = c.CreateCommand())
   {
   cmd.CommandText = ...;
   using (IDataReader reader = cmd.ExecuteReader();
   {
   while (reader.Read())
   {
   }
   }
}
==


--
Emil R. Emilov
---
mailto:[EMAIL PROTECTED]
http://www.emilov.de
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Re: Mono-list Digest, Vol 4, Issue 5 sender for your account)

2005-08-04 Thread mono-list . 1 . tracyanne
I realised what I was doing wrong. I didn't have the test for null if
(InputError != null) in my original code, and as I wasn't at the time
subscribing to the event, it was naturally going to error out.

By the way the code I sent in is pretty much what you'll find on page
309 (Chapter 6 Advanced C# Topics) of Wrox's Professional C#. That's
where i copied it from, for my project.

regards

Tracy Barlow



 Date: Thu, 04 Aug 2005 01:56:52 -0700
 From: Jackson Harper [EMAIL PROTECTED]
 Subject: Re: [Mono-list] Problem with Events
 To: mono-list@lists.ximian.com
 Message-ID: [EMAIL PROTECTED]
 Content-Type: text/plain
 
 On Thu, 2005-08-04 at 17:30 +1000, [EMAIL PROTECTED]
 wrote:
  Can anyone see anything wrong with this code. It looks to me to be
  correct syntax for defining and raising an event. It compiles without
  error, but when I run it I get the following error message
 
 Nothing is ever subscribing to your event, so it is null when you are
 trying to invoke it. You need something like:
 
 OnInputError += new InputError (ErrorHandlerFunction); somewhere.
 
 A few general style comments:
 
 1. Normally event handler delegates are named somethingHandler. So
 your InputError delegate would be named InputErrorHandler.
 
 2. Normally events names don't start with On. So OnInputError would be
 InputError.
 
 3. It's common to wrap the instantiation of an event in a protected
 method named OnEvent Name. So you would have a method that looks like
 this:
 
 protected void OnInputError (InputErrorEventArgs e)
 {
 if (InputError != null)
 InputError (this, e);
 }
 
 
 Cheers,
 Jackson
 
 
  
  Unhandled Exception: System.NullReferenceException: Object reference not
  set to an instance of an object
  in [0x1] (at /home/tracy/MonoDevelop/TestEvents/Main.cs:22)
  RaiseAnEvent:Run ()
  in [0x7] (at /home/tracy/MonoDevelop/TestEvents/Main.cs:11)
  MainClass:Main (System.String[] args)
  
  I'm using Mono_1.1.8-2.
  
  // project created on 04/08/2005 at 17:17
  using System;
  
  class MainClass
  {
  
  public static void Main(string[] args)
  {
  RaiseAnEvent RAE = new RaiseAnEvent();
  RAE.Run();
  }
  }
  
  class RaiseAnEvent
  {
  public delegate void InputError(object sender, InputErrorEventArgs e);
  public event InputError OnInputError;
  
  public void Run()
  {
  OnInputError(this, new InputErrorEventArgs(DF, OI));
  }
  
  }
  
  
  //Class for passing Input Error messages to the application
  class InputErrorEventArgs : EventArgs
  {
  private string errorMessage;
  private string errorSource;
  
  public string ErrorMessage
  {
  get
  {
  return errorMessage;
  }
  }
  
  public string ErrorSource
  {
  get
  {
  return errorSource;
  }
  }
  
  public InputErrorEventArgs(string Message, string Source) : base()
  {
  errorMessage = Message;
  errorSource = Source;
  }
  }
  ___
  Mono-list maillist  -  Mono-list@lists.ximian.com
  http://lists.ximian.com/mailman/listinfo/mono-list
 
 
 
 --
 
 ___
 Mono-list mailing list
 Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list
 
 
 End of Mono-list Digest, Vol 4, Issue 5
 ***
 
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Gnome and Kde and how the mono project works with them .......

2005-08-04 Thread ted leslie
I have just recently run in to a gtk-sharp issue on
a kde desktop. Went to gnome on the same machine, and all is fine.

It just got me thinking ..
I don't really have a preference to either desk top, i just have been running
KDE for years and years because it probably came up stock on an old distro.

I see obviously direct support for gnome in the mono project, and of course
gtk# appears to be where its at right now for gui with mono apps.

That having been said .. I am about to roll out some mono/gtk# apps
to a pool of about 1000 people working for various fortune 500 companies in
US and fortune 50 companies in Canada.

and I pick the desktop they run, and until now that is KDE.

Since I am doing everything now in mono/gtk# on Linux (for these clients),
(now) and  in time want to have the most optimum desktop environment
for these people,
is it correct to say I should obviously be switching to Gnome
based on the Mono project direction? 

If anyone were to guess..what percentage of mono lead developers/maintainers
use gnome  vs. kde?

As far as I gather, mono/gtk# app. will work fine on both desktops
but with gnome there will be synergy amongst apps (i.e. drag on to)
that KDE will not have? And if this is the case, anyone thought about
that type of support for KDE?

Is there perhaps maybe a bit of hidden politics at work here too?
but I find it odd ... Novell bought SUSE, Novell funds mono (to some extent),
suse distro's default to KDE do they not? (pretty sure 9.0/9.1/9.2 do)?
Since we see Novell funding mono, owning SUSE, and talk of how tight
Gnome and mono may become  what is the outlook/piture of KDE in the future.

Looks like I am switching to Gnome unless my hunch (post) is completely
off base. 

-tl

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Gnome and Kde and how the mono project works with them .......

2005-08-04 Thread Harry Holt
Gee, tl, are you sure you want your clients to go through all that
re-training and dealing with the (temporary) productivity loss while
everyone gets acclimated to the new desktop?  Not to mention all the
documentation issues, lots of new configuration file changes, etc.,
that you'll need to deal with.  Why not just stick with KDE?

If you are concerned about being able to integrate your mono
applications smoothly with qt-based interfaces, I would be glad to
offer my services as a technical specialist and programmer to ensure
your users won't have to deal with functionality gaps and kludgy
interfaces to stay with your current environment :-)

[sorry if this is a little off-topic]
Harry Holt


On 8/4/05, ted leslie [EMAIL PROTECTED] wrote:
 I have just recently run in to a gtk-sharp issue on
 a kde desktop. Went to gnome on the same machine, and all is fine.
 
 It just got me thinking ..
 I don't really have a preference to either desk top, i just have been running
 KDE for years and years because it probably came up stock on an old distro.
 
 I see obviously direct support for gnome in the mono project, and of course
 gtk# appears to be where its at right now for gui with mono apps.
 
 That having been said .. I am about to roll out some mono/gtk# apps
 to a pool of about 1000 people working for various fortune 500 companies in
 US and fortune 50 companies in Canada.
 
 and I pick the desktop they run, and until now that is KDE.
 
 Since I am doing everything now in mono/gtk# on Linux (for these clients),
 (now) and  in time want to have the most optimum desktop environment
 for these people,
 is it correct to say I should obviously be switching to Gnome
 based on the Mono project direction?
 
 If anyone were to guess..what percentage of mono lead developers/maintainers
 use gnome  vs. kde?
 
 As far as I gather, mono/gtk# app. will work fine on both desktops
 but with gnome there will be synergy amongst apps (i.e. drag on to)
 that KDE will not have? And if this is the case, anyone thought about
 that type of support for KDE?
 
 Is there perhaps maybe a bit of hidden politics at work here too?
 but I find it odd ... Novell bought SUSE, Novell funds mono (to some extent),
 suse distro's default to KDE do they not? (pretty sure 9.0/9.1/9.2 do)?
 Since we see Novell funding mono, owning SUSE, and talk of how tight
 Gnome and mono may become  what is the outlook/piture of KDE in the 
 future.
 
 Looks like I am switching to Gnome unless my hunch (post) is completely
 off base.
 
 -tl
 
 ___
 Mono-list maillist  -  Mono-list@lists.ximian.com
 http://lists.ximian.com/mailman/listinfo/mono-list
 


-- 

Robbie the Nanobot says:
Only YOU can prevent gray goo
(NEVER release nanobot assemblers without replication limiting code)
http://lizardslounge.org
___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Gnome and Kde and how the mono project works with them .......

2005-08-04 Thread Jonathan Pryor
On Thu, 2005-08-04 at 22:00 -0400, ted leslie wrote:
 I have just recently run in to a gtk-sharp issue on
 a kde desktop. Went to gnome on the same machine, and all is fine.

It would be useful to know what the issue is.  The goal is to allow
desktop-agnostic applications, by using freedesktop.org standards when
possible.  (This isn't always possible, such as with theme changes and
file  print dialogs, but the apps should work properly, even if they
don't form a coherent whole...)

 Since I am doing everything now in mono/gtk# on Linux (for these clients),
 (now) and  in time want to have the most optimum desktop environment
 for these people,
 is it correct to say I should obviously be switching to Gnome
 based on the Mono project direction? 

As Harry Holt mentioned, you should choose whichever environment is best
suited for your users.  Re-training them may not be cost effective.

Plus, it's always possible that someone will write a Qt# binding layer
to allow better KDE interop.

 If anyone were to guess..what percentage of mono lead developers/maintainers
 use gnome  vs. kde?

100% Gnome, AFAIK (though it would help to define lead developers).

However, it should be noted that most of mono doesn't depend on Gnome or
KDE -- XML, File I/O, everything that isn't GUI-related is completely
desktop agnostic, so it doesn't matter that lupus (JIT guy
extraordinaire) is running Gnome or FLTK or FluxBox, as the JIT doesn't
change on any of those.

With that being said, all Mono-related Novell-funded resources are going
into Gtk# and System.Windows.Forms, not Qt#.  (Which isn't to say that
KDE isn't getting any resources from Novell, just no resources that are
Mono-related, from what I've seen.)

 As far as I gather, mono/gtk# app. will work fine on both desktops
 but with gnome there will be synergy amongst apps (i.e. drag on to)
 that KDE will not have? And if this is the case, anyone thought about
 that type of support for KDE?

Drag-and-drop should work.  Copy/paste should work.  If they don't work,
then someone isn't adhering to the relevant freedesktop.org standards.

What will differ?  Themes, dialog boxes, HIG conventions (Mac-style
[Cancel][Save] button layout vs. Windows [OK][Cancel] button layout),
and more.

Will those differences matter?  It depends on the training your users
receive.  For example, Microsoft Office tends to have different widgets
and conventions than every other Windows app, yet it does very well. :-)

Training can make up for a lot.  Don't underestimate its importance.

Don't underestimate the harm of Change for Changes sake, either.  Many
users don't like change.

 Is there perhaps maybe a bit of hidden politics at work here too?
 but I find it odd ... Novell bought SUSE, Novell funds mono (to some extent),
 suse distro's default to KDE do they not? (pretty sure 9.0/9.1/9.2 do)?

The missing piece is that Novell bought Ximian, which originally
developed Mono and is a big Gnome developer.

From the outside, Novell seems to be supporting both Gnome and KDE, but
as far as Mono is concerned Gnome is getting all the support.

 Since we see Novell funding mono, owning SUSE, and talk of how tight
 Gnome and mono may become  what is the outlook/piture of KDE in the 
 future.

You'd have to ask the KDE developers that, and I'm sure they feel the
future of KDE is bright.  Whether they see Mono in their future is
another matter, and whether Mono is part of Gnome's future will cause
flame wars for years to come. :-)

 - Jon


___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Npgsql error

2005-08-04 Thread Jaroslaw Kowalski

Cool, a question on that:
What happens if a exception occurs?
I meand close() gets called at the end of the using block, but does it get 
also called when an exception occurs (sort of finally)?

If yes, I'm changing my programming style :)
Another question, how would it look like if you had to catch an exception 
(i.e. to rollback a transaction)?


The following code:


using (A a = new A())
{
   code
};


Is equivalent to:

===
A a = null;

try
{
   a = new A();
   /// code
}
finally
{
   if (a != null) ((IDisposable)a).Dispose();
}
===

It's the C# compiler that translates every using() to something like the 
above code. The IDisposable.Dispose method on data providers automatically 
rolls back any open and uncommitted transactions so you don't need to do 
explicit rollbacks.


BTW. I've seen many (MS and other) examples where they don't call Dispose 
the IDbCommand object, even though it implements IDisposable, I'm not sure 
whether it leads to potential resource leaks or not.


--
Jaroslaw Kowalski
http://blog.jkowalski.net/

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


[Mono-list] Datawindows

2005-08-04 Thread mono-list . 1 . tracyanne
I've been Working on a Data Bound DataGrid that is based on Gtk# Widgets
(Scrolled Window, TreeView, ListStore, Cellrenderer). It uses the
WinForms DataGrid paradigm for for consuming Data providers, it's a work
in progress (although it is sufficiently useful for my needs as it is).
You are welcome to the code for it.

I will be developing other DataBound Controls as I go.

Regards

Tracy Barlow

 Date: Fri, 05 Aug 2005 01:01:26 +0200
 From: (Aesux) [EMAIL PROTECTED]
 Subject: [Mono-list] Datawindows
 To: mono-list@lists.ximian.com
 Message-ID: [EMAIL PROTECTED]
 Content-Type: text/plain; charset=ISO-8859-15; format=flowed
 
 
 Hi,
 
 Perhaps anyone know about the Sybase RAD PowerBuilder, isn't it? Then 
 sure you know about the functionality and power of its Datawindow Control.
 
 My question was if there is anything similar usable yet under mono or 
 any other GPL development platform, or free at least. Any control or 
 widget with similar power to Poweruilder DW?
 
 I know Winforms will have a DataGrid control, but, I don't know about 
 its real functionality and power, and I don't know about its timing 
 roadmap for use it in production envirnoment.
 
 Thanks in advance,
 
 
 -- 
 
 Pere (Aesux)
 GNU/Linux 2.6.11-1.1369_FedoraCore4

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list


Re: [Mono-list] Sqlite version

2005-08-04 Thread Julien Sobrier

Chris Turchin a écrit :

It works with 2.8.16 and 3.1.3 at any rate. I have tested both.

Regards,

--chris


With what version of Mono? I've tried Sqlite 3.0.8 and 
Mono.Data.SqliteClient doesn't recognize the database format.


Thank you
Julien

___
Mono-list maillist  -  Mono-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-list