RE: [Mono-dev] MonoDebuggerSupport.GetLocalIndex call ingmcs/symbolwriter.cs

2005-12-16 Thread Jakob Andersen
I found the solution myself. And I have to admit that I remembered the
semantics of internal a bit wrong.

The internal class can of course be called from Mono.Csharp because the
Mono.CompilerServices namespace is included in the same assembly i.e.
gmcs.exe.

Sorry to trouble you with my shortcomings :-)

-- 
Best Regards,
Jakob Andersen

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jakob
Andersen
Sent: 14. december 2005 17:39
To: mono-devel-list@lists.ximian.com
Subject: [Mono-dev] MonoDebuggerSupport.GetLocalIndex call
ingmcs/symbolwriter.cs

Hi All,

I am a bit puzzled about the call to MonoDebuggerSupport.GetLocalIndex(...)
in SymbolWriter.DefineLocalVariable(...)

As I see it the MonoDebuggerSupport is a internal class in the namespace
Mono.CompilerServices.SymbolWriter and can not be called in
SymbolWiter.DefineLocalVariable(..) that is in Mono.CSharp namespace?

Have I missed something here?

--
Best Regards,
Jakob Andersen

___
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-dev] MonoDebuggerSupport.GetLocalIndex call ingmcs/symbolwriter.cs

2005-12-16 Thread Jakob Andersen
I found the solution myself. And I have to admit that I remembered the
semantics of internal a bit wrong.

The internal class can of course be called from Mono.Csharp because the
Mono.CompilerServices namespace is included in the same assembly i.e.
gmcs.exe.

Sorry to trouble you with my shortcomings :-)

-- 
Best Regards,
Jakob Andersen

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jakob
Andersen
Sent: 14. december 2005 17:39
To: mono-devel-list@lists.ximian.com
Subject: [Mono-dev] MonoDebuggerSupport.GetLocalIndex call
ingmcs/symbolwriter.cs

Hi All,

I am a bit puzzled about the call to MonoDebuggerSupport.GetLocalIndex(...)
in SymbolWriter.DefineLocalVariable(...)

As I see it the MonoDebuggerSupport is a internal class in the namespace
Mono.CompilerServices.SymbolWriter and can not be called in
SymbolWiter.DefineLocalVariable(..) that is in Mono.CSharp namespace?

Have I missed something here?

--
Best Regards,
Jakob Andersen

___
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-dev] Found a Mono mention on a microsoft page

2005-12-16 Thread Maxime de Lavenne




  Looks 
like they might. 

  
  
  From: Felipe Almeida Lessa 
  [mailto:[EMAIL PROTECTED] Sent: Friday, December 16, 2005 
  10:54 AMTo: Maxime de LavenneCc: 
  mono-devel-list@lists.ximian.comSubject: Re: [Mono-dev] Found a 
  Mono mention on a microsoft page
  2005/12/16, Maxime de Lavenne <[EMAIL PROTECTED]>:
  
  http://www.microsoft.com/downloads/details.aspx?FamilyID=22914587-b4ad-4eae-87cf-b14ae6a939b0&displaylang=en
  "It does not yet support Rotor or Mono.""Yet"? Will 
  they support some day?--  
   
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-dev] Accessing Loaded Assembly Data

2005-12-16 Thread Jim Purbrick
Hi everyone,

I'm currently using Assembly.Load(byte[]) to load
assemblies from memory. Is there a way to get the byte
array back later using either the .NET or Mono
embedding APIs? I don't want to have to keep a copy
hanging around in memory if I can ask for the array
back again.

Merry Christmas!

Jim.



___ 
Yahoo! Exclusive Xmas Game, help Santa with his celebrity party - 
http://santas-christmas-party.yahoo.net/
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-dev] IE ignoring bordercolor from datagrid

2005-12-16 Thread Carlos Solorzano
I have a datagrid with a bordercolor (as shown below) and for some 
reason when the html comes out (as shown below) it does not have the 
border color.


CellSpacing="2" BorderStyle="None" BorderColor="#ff" id="Grid" 
Runat="server" CellPadding="3">


The html that comes out of XSP:



The html that comes out of ms.net:



I think that bordercolor="White" makes the big difference.

--Carlos

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


[Mono-dev] [PATCH] Update Gendarme framework

2005-12-16 Thread Aaron Tomb
Hi,

I've updated the Gendarme rule execution framework as I described in my
earlier mail. Notably:

  * All of the Check* methods from the IRule interface now accept one
extra parameter, a Runner, which can be a useful source of
configuration information, such as command-line flags.

  * All of the Check* methods now return an IList, instead of bool. This
list is intended to contain Message objects, giving details of the
rule violation (particularly, the relevant locations within
methods). In cases where you would previously return 'true', you
should now return null. In cases where you would return 'false', but
have no extra information, return an empty list (i.e., new
ArrayList()). In cases where you want to provide extra information,
create Message objects, and populate the list before returning it.

  * The ConsoleRunner now accepts the --debug flag, which sets the
property Debug. All rules can now conditionally produce debugging
information.

  * All of the code using these interfaces has been updated.

Beware that, currently, NullDerefRule generates a lot of output on
almost any assembly. Therefore, you may want to use the --set option to
specify exactly which set of rules you want to run.

I've attached a diff generated with 'svn diff' in the cecil/gendarme
directory.

Aaron
Index: console/ConsoleRunner.cs
===
--- console/ConsoleRunner.cs(revision 54494)
+++ console/ConsoleRunner.cs(working copy)
@@ -86,6 +86,9 @@
case "--set":
set = GetNext (args, ++i, defaultRuleSet);
break;
+   case "--debug":
+   debug = true;
+   break;
case "--help":
return false;
default:
@@ -154,6 +157,7 @@
Console.WriteLine ("Where");
Console.WriteLine ("  --config configfile\tSpecify the 
configuration file. Default is 'rules.xml'.");
Console.WriteLine ("  --set ruleset\t\tSpecify the set of rules 
to verify. Default is '*'.");
+   Console.WriteLine ("  --debug\t\tEnable debugging output.");
Console.WriteLine ("  assembly\t\tSpecify the assembly to 
verify.");
Console.WriteLine ();
}
@@ -202,6 +206,13 @@
Console.WriteLine ();
Console.WriteLine ("Problem: {0}", String.Format 
(ri.Problem, v.Violator));
Console.WriteLine ();
+   if(v.Messages != null && v.Messages.Count > 0) {
+   Console.WriteLine ("Details:");
+   foreach(object message in v.Messages) {
+   Console.WriteLine("  {0}", message);
+   }
+   Console.WriteLine ();
+   }
Console.WriteLine ("Solution: {0}", String.Format 
(ri.Solution, v.Violator));
Console.WriteLine ();
string url = ri.Uri;
Index: rules/Gendarme.Rules.Security/Test/TypeExposeFieldsTest.cs
===
--- rules/Gendarme.Rules.Security/Test/TypeExposeFieldsTest.cs  (revision 54494)
+++ rules/Gendarme.Rules.Security/Test/TypeExposeFieldsTest.cs  (working copy)
@@ -123,42 +123,42 @@
public void NonPublic ()
{
ITypeDefinition type = GetTest ("NonPublicClass");
-   Assert.IsTrue (rule.CheckType (assembly, module, type));
+   Assert.IsNull (rule.CheckType (assembly, module, type, 
new MinimalRunner()));
}
 
[Test]
public void NoSecurity ()
{
ITypeDefinition type = GetTest ("NoSecurityClass");
-   Assert.IsTrue (rule.CheckType (assembly, module, type));
+   Assert.IsNull (rule.CheckType (assembly, module, type, 
new MinimalRunner()));
}
 
[Test]
public void NoDemand ()
{
ITypeDefinition type = GetTest ("NoDemandClass");
-   Assert.IsTrue (rule.CheckType (assembly, module, type));
+   Assert.IsNull (rule.CheckType (assembly, module, type, 
new MinimalRunner()));
}
 
[Test]
public void NoPublicField ()
{
ITypeDefinition type = GetTest ("NoPublicFieldClass");
-   Assert.IsTrue (rule.CheckType (assembly, module, type));
+   Assert.IsNull (rule.CheckType (assembly, module, type, 
new MinimalRunner()));

Re: [Mono-dev] Found a Mono mention on a microsoft page

2005-12-16 Thread Felipe Almeida Lessa
2005/12/16, Maxime de Lavenne <[EMAIL PROTECTED]>:
http://www.microsoft.com/downloads/details.aspx?FamilyID=22914587-b4ad-4eae-87cf-b14ae6a939b0&displaylang=en
"It does not yet support Rotor or Mono.""Yet"? Will they support some day?-- "Quem excele em empregar a força militar subjulga os exércitos dos outros
povos sem travar batalha, toma cidades fortificadas dos outros povos sem asatacar e destrói os estados dos outros povos sem lutas prolongadas. Develutar sob o Céu com o propósito primordial da 'preservação'. Desse modo suas
armas não se embotarão, e os ganhos poderão ser preservados. Essa é a estratégia para planejar ofensivas."  -- Sun Tzu, em "A arte da guerra"
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


[Mono-dev] Found a Mono mention on a microsoft page

2005-12-16 Thread Maxime de Lavenne
Just a quick note to say it's really cool to see Mono mentioned on a
microsoft web page... I know it's a just a quick mention, but it's nice to
see they are planning to support mono as well in ILMerge.

http://www.microsoft.com/downloads/details.aspx?FamilyID=22914587-b4ad-4eae-
87cf-b14ae6a939b0&displaylang=en


Max


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


Re: [Mono-dev] LINQ Standard Query Operators for Mono

2005-12-16 Thread Alejandro Serrano

I attach a .tar.gz file with the implementation.

Alejandro

P.D.: Is there any plan to create a DLinq-like thing for Mono?

Atsushi Eno escribió:


Hi,

Alejandro Serrano wrote:

I finally finished implementing the LINQ System.Query code. Some things 



congrats :-)

were a bit tricky, because Dictionary doesn't allow null 
values, so I had to make some additional checks on Grouping 
operators. I've created a Makefile in order to be included in the 
mcs/class/System.Query folder, but I don't know if it is well done.



Having mcs/class/System.Query would be fine, but for now we don't
have to integrate this directory in our build process (System.Xml.XLinq
isn't integrated, as well).

Where do I send the code? In a zip file directly to this list? Or to 
anyone in particular?



zip file would be ok. This list has message size limitation to 80kb
or whatever (in that case some of us can approve it). If it is much
bigger (I guess not), I can upload somewhere for you.


Alejandro

P.D.: I hope extension methods get in Mono C# compiler very soon, 
because this would allow to use this operators ver easily. Other C# 
3.0 features such as lambda expressions of query-like expressions 
aren't as important as this, but I think extension methods are both 
easy to implement (just check some more classes) and very helpful. Of 
course, this is just my idea :-)



It won't happen very soon. For C# 3.0 features, you will have to wait
at least to get it checked in svn (local gmcs patches are always 
possible). See

http://tirania.org/blog//texts/mono-status.html#csharp

Atsushi Eno





System.Query.tar.gz
Description: GNU Zip compressed data
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Response.Redirect possible exception when using forms authentication

2005-12-16 Thread Robert Jordan

Carlos Solorzano wrote:

I changed my code to not do a RedirectFromLoginPage() but instead get  
the authentication cookie and do a Response.Redirect(url,FALSE), and  
that FALSE made it all work again. What I don't understand is what is  
keeping the thread from being aborted, is there an easy way to find  
that out? and why is no error actually showing up on the page?


Because it's how Response.End() and Respose.Redirect(url)
work: the execution of the page is aborted when one of
the methods gets called. This is documented and by design.

Using Respose.Redirect(url, false) leads to an unnecessary
and sometimes confusing page rendering.

Robert

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


Re: [Mono-dev] Response.Redirect possible exception when using forms authentication

2005-12-16 Thread Dieter Bremes

Carlos Solorzano wrote:


On Dec 16, 2005, at 2:55 AM, Carlos Solorzano wrote:


I am using forms authentication with XSP on mono 1.1.10.1
Whenever a user logs in, sometimes, the login page never responds  
after entering the username and password. I went ahead and tried to  
figure out where its getting stuck. I am almost certain now that  the 
End() method on HttpResponse.cs can throw the exception given  below. 
Try Catching that exception makes my forms authentication  work 
correctly almost always now.
Is there maybe something wrong I could be doing on my code? I know  
that sometimes having Try Catch blocks on Redirects can cause  
problems but I don't have any as far as I can tell, either-way I  
think an error should be shown to the user if thats the case, right  
now the code just doesn't respond.


Anyways here is the exception:

System.Threading.ThreadAbortException: Thread was being aborted
in (wrapper managed-to-native)  
System.Object:__icall_wrapper_mono_thread_interruption_checkpoint ()
in (wrapper managed-to-native)  System.Threading.Thread:Abort_internal 
(object)

in <0x0001a> System.Threading.Thread:Abort (System.Object stateInfo)
in <0x00071> System.Web.HttpResponse:End ()




I changed my code to not do a RedirectFromLoginPage() but instead get  
the authentication cookie and do a Response.Redirect(url,FALSE), and  
that FALSE made it all work again. What I don't understand is what is  
keeping the thread from being aborted, is there an easy way to find  
that out? and why is no error actually showing up on the page?


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



Hi Carlos,

looks like in FormsAuthentication.cs

public static void RedirectFromLoginPage (...)
{
  // ...
  Redirect (GetRedirectUrl (userName, createPersistentCookie));
}

should be

public static void RedirectFromLoginPage (...)
{
  // ...
  Redirect (GetRedirectUrl (userName, createPersistentCookie), false);
}

http://weblogs.asp.net/bleroy/archive/2004/08/03/207486.aspx explains it.

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


[Mono-dev] Possible bug in ASP.NET when using webcontrols within script tag.

2005-12-16 Thread Peter Magnusson
There is a problem when using webcontrols witin a javascript script tag in mono.
The code below works in windows NET 1.1 but not in mono

I have mono from revision 54118 and xsp from rev 54397



 test.aspx 
<%@ Page Language="C#" %>




void Page_Load(object sender, EventArgs e)
{

testHolder.Controls.Add(new LiteralControl(""));
}
















 end test.aspx 
--
Peter Magnusson
[EMAIL PROTECTED] | http://crippledcanary.se
___
Mono-devel-list mailing list
Mono-devel-list@lists.ximian.com
http://lists.ximian.com/mailman/listinfo/mono-devel-list


Re: [Mono-dev] Response.Redirect possible exception when using forms authentication

2005-12-16 Thread Carlos Solorzano


On Dec 16, 2005, at 2:55 AM, Carlos Solorzano wrote:


I am using forms authentication with XSP on mono 1.1.10.1
Whenever a user logs in, sometimes, the login page never responds  
after entering the username and password. I went ahead and tried to  
figure out where its getting stuck. I am almost certain now that  
the End() method on HttpResponse.cs can throw the exception given  
below. Try Catching that exception makes my forms authentication  
work correctly almost always now.
Is there maybe something wrong I could be doing on my code? I know  
that sometimes having Try Catch blocks on Redirects can cause  
problems but I don't have any as far as I can tell, either-way I  
think an error should be shown to the user if thats the case, right  
now the code just doesn't respond.


Anyways here is the exception:

System.Threading.ThreadAbortException: Thread was being aborted
in (wrapper managed-to-native)  
System.Object:__icall_wrapper_mono_thread_interruption_checkpoint ()
in (wrapper managed-to-native)  
System.Threading.Thread:Abort_internal (object)

in <0x0001a> System.Threading.Thread:Abort (System.Object stateInfo)
in <0x00071> System.Web.HttpResponse:End ()



I changed my code to not do a RedirectFromLoginPage() but instead get  
the authentication cookie and do a Response.Redirect(url,FALSE), and  
that FALSE made it all work again. What I don't understand is what is  
keeping the thread from being aborted, is there an easy way to find  
that out? and why is no error actually showing up on the page?


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


[Mono-dev] Response.Redirect possible exception when using forms authentication

2005-12-16 Thread Carlos Solorzano

I am using forms authentication with XSP on mono 1.1.10.1
Whenever a user logs in, sometimes, the login page never responds  
after entering the username and password. I went ahead and tried to  
figure out where its getting stuck. I am almost certain now that the  
End() method on HttpResponse.cs can throw the exception given below.  
Try Catching that exception makes my forms authentication work  
correctly almost always now.
Is there maybe something wrong I could be doing on my code? I know  
that sometimes having Try Catch blocks on Redirects can cause  
problems but I don't have any as far as I can tell, either-way I  
think an error should be shown to the user if thats the case, right  
now the code just doesn't respond.


Anyways here is the exception:

System.Threading.ThreadAbortException: Thread was being aborted
in (wrapper managed-to-native)  
System.Object:__icall_wrapper_mono_thread_interruption_checkpoint ()
in (wrapper managed-to-native) System.Threading.Thread:Abort_internal  
(object)

in <0x0001a> System.Threading.Thread:Abort (System.Object stateInfo)
in <0x00071> System.Web.HttpResponse:End ()

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