1111using System . Collections . Generic ;
1212using System . ComponentModel ;
1313using System . Data ;
14- using System . Data . Common ;
15- using System . Data . SqlClient ;
16- using System . Diagnostics ;
17- using System . Diagnostics . Eventing ;
18- using System . Diagnostics . Eventing . Reader ;
19- using System . Diagnostics . PerformanceData ;
2014using System . Dynamic ;
21- using System . Globalization ;
22- using System . IO ;
23- using System . IO . Compression ;
24- using System . IO . IsolatedStorage ;
25- using System . IO . Pipes ;
26- using System . IO . Ports ;
2715using System . Linq ;
2816using System . Linq . Expressions ;
29- using System . Net ;
30- using System . Net . Mail ;
31- using System . Net . NetworkInformation ;
32- using System . Net . Security ;
33- using System . Net . Sockets ;
3417using System . Reflection ;
35- using System . Reflection . Emit ;
36- using System . Resources ;
37- using System . Security ;
38- using System . Security . AccessControl ;
39- using System . Security . Cryptography ;
40- using System . Security . Cryptography . X509Certificates ;
41- using System . Security . Principal ;
4218using System . Text ;
4319using System . Text . RegularExpressions ;
44- using System . Threading ;
45- using System . Threading . Tasks ;
46- using System . Xml ;
47- using System . Xml . Linq ;
4820using System . Xml . Schema ;
49- using System . Xml . Serialization ;
5021using System . Xml . XPath ;
5122using System . Xml . Xsl ;
52- using EventDescriptor = System . ComponentModel . EventDescriptor ;
5323
5424namespace Z . Expressions
5525{
5626 public partial class EvalContext
5727 {
5828 /// <summary>Registers default alias (Extension Methods, Names, Static Members, Types and Values).</summary>
59- public void RegisterDefaultAlias ( )
29+ public void RegisterDefaultAliasSafe ( )
6030 {
6131 // Extension Methods
6232 RegisterExtensionMethod ( typeof ( Enumerable ) ) ;
@@ -132,21 +102,21 @@ public void RegisterDefaultAlias()
132102 // System.IO
133103
134104 // System.IO.Compression
135- RegisterType ( typeof ( GZipStream ) ) ;
105+ // RegisterType(typeof (GZipStream));
136106
137107 // System.IO.IsolatedStorage
138- RegisterType ( typeof ( IsolatedStorage ) ) ;
108+ // RegisterType(typeof (IsolatedStorage));
139109
140110 // System.IO.Pipes
141- RegisterType ( typeof ( AnonymousPipeClientStream ) ) ;
142- RegisterType ( typeof ( AnonymousPipeServerStream ) ) ;
143- RegisterType ( typeof ( NamedPipeClientStream ) ) ;
144- RegisterType ( typeof ( NamedPipeServerStream ) ) ;
145- RegisterType ( typeof ( PipeSecurity ) ) ;
146- RegisterType ( typeof ( PipeStream ) ) ;
111+ // RegisterType(typeof (AnonymousPipeClientStream));
112+ // RegisterType(typeof (AnonymousPipeServerStream));
113+ // RegisterType(typeof (NamedPipeClientStream));
114+ // RegisterType(typeof (NamedPipeServerStream));
115+ // RegisterType(typeof (PipeSecurity));
116+ // RegisterType(typeof (PipeStream));
147117
148118 // System.IO.Ports
149- RegisterType ( typeof ( SerialPort ) ) ;
119+ // RegisterType(typeof (SerialPort));
150120
151121 // System.Linq
152122 RegisterType ( typeof ( IQueryable < > ) ) ;
@@ -157,40 +127,40 @@ public void RegisterDefaultAlias()
157127 RegisterType ( typeof ( Expression ) ) ;
158128
159129 // System.Reflection
160- RegisterType ( typeof ( Assembly ) ) ;
161- RegisterType ( typeof ( ConstructorInfo ) ) ;
162- RegisterType ( typeof ( FieldInfo ) ) ;
163- RegisterType ( typeof ( MemberInfo ) ) ;
164- RegisterType ( typeof ( MethodInfo ) ) ;
165- RegisterType ( typeof ( PropertyInfo ) ) ;
130+ // RegisterType(typeof (Assembly));
131+ // RegisterType(typeof (ConstructorInfo));
132+ // RegisterType(typeof (FieldInfo));
133+ // RegisterType(typeof (MemberInfo));
134+ // RegisterType(typeof (MethodInfo));
135+ // RegisterType(typeof (PropertyInfo));
166136
167137 // System.Reflection.Emit
168- RegisterType ( typeof ( AssemblyBuilder ) ) ;
169- RegisterType ( typeof ( MethodBuilder ) ) ;
170- RegisterType ( typeof ( TypeBuilder ) ) ;
138+ // RegisterType(typeof (AssemblyBuilder));
139+ // RegisterType(typeof (MethodBuilder));
140+ // RegisterType(typeof (TypeBuilder));
171141
172142 // System.Resources
173- RegisterType ( typeof ( ResourceManager ) ) ;
143+ // RegisterType(typeof (ResourceManager));
174144
175145 // System.Security
176- RegisterType ( typeof ( SecureString ) ) ;
177- RegisterType ( typeof ( SecurityManager ) ) ;
146+ // RegisterType(typeof (SecureString));
147+ // RegisterType(typeof (SecurityManager));
178148
179149 // System.Security.AccessControl
180- RegisterType ( typeof ( AccessRule ) ) ;
181- RegisterType ( typeof ( FileSecurity ) ) ;
182- RegisterType ( typeof ( ObjectSecurity ) ) ;
150+ // RegisterType(typeof (AccessRule));
151+ // RegisterType(typeof (FileSecurity));
152+ // RegisterType(typeof (ObjectSecurity));
183153
184154 // System.Security.Cryptography
185- RegisterType ( typeof ( ECDsaCng ) ) ;
186- RegisterType ( typeof ( SHA1 ) ) ;
187- RegisterType ( typeof ( TripleDES ) ) ;
155+ // RegisterType(typeof (ECDsaCng));
156+ // RegisterType(typeof (SHA1));
157+ // RegisterType(typeof (TripleDES));
188158
189159 // System.Security.Cruptography.X509Certificates
190- RegisterType ( typeof ( X509Store ) ) ;
160+ // RegisterType(typeof (X509Store));
191161
192162 // System.Security.Principal
193- RegisterType ( typeof ( WindowsIdentity ) ) ;
163+ // RegisterType(typeof (WindowsIdentity));
194164
195165 // System.Text
196166 RegisterType ( typeof ( Encoding ) ) ;
@@ -200,107 +170,107 @@ public void RegisterDefaultAlias()
200170 RegisterType ( typeof ( Regex ) ) ;
201171
202172 // System.Threading
203- RegisterType ( typeof ( ReaderWriterLockSlim ) ) ;
204- RegisterType ( typeof ( Semaphore ) ) ;
205- RegisterType ( typeof ( Thread ) ) ;
206- RegisterType ( typeof ( WaitHandle ) ) ;
173+ // RegisterType(typeof (ReaderWriterLockSlim));
174+ // RegisterType(typeof (Semaphore));
175+ // RegisterType(typeof (Thread));
176+ // RegisterType(typeof (WaitHandle));
207177 }
208178
209179 // Communications and Workflow
210180 {
211181 // System.Net
212- RegisterType ( typeof ( Dns ) ) ;
213- RegisterType ( typeof ( FtpWebRequest ) ) ;
214- RegisterType ( typeof ( HttpListener ) ) ;
215- RegisterType ( typeof ( HttpWebRequest ) ) ;
216- RegisterType ( typeof ( WebClient ) ) ;
182+ // RegisterType(typeof (Dns));
183+ // RegisterType(typeof (FtpWebRequest));
184+ // RegisterType(typeof (HttpListener));
185+ // RegisterType(typeof (HttpWebRequest));
186+ // RegisterType(typeof (WebClient));
217187
218188 // System.Net.Mail
219- RegisterType ( typeof ( MailMessage ) ) ;
220- RegisterType ( typeof ( SmtpClient ) ) ;
189+ // RegisterType(typeof (MailMessage));
190+ // RegisterType(typeof (SmtpClient));
221191
222192 // System.Net.NetworkInformation
223- RegisterType ( typeof ( NetworkInterface ) ) ;
224- RegisterType ( typeof ( NetworkChange ) ) ;
225- RegisterType ( typeof ( Ping ) ) ;
193+ // RegisterType(typeof (NetworkInterface));
194+ // RegisterType(typeof (NetworkChange));
195+ // RegisterType(typeof (Ping));
226196
227197 // System.Net.Security
228- RegisterType ( typeof ( NegotiateStream ) ) ;
229- RegisterType ( typeof ( SslStream ) ) ;
198+ // RegisterType(typeof (NegotiateStream));
199+ // RegisterType(typeof (SslStream));
230200
231201 // System.Net.Sockets
232- RegisterType ( typeof ( NetworkStream ) ) ;
233- RegisterType ( typeof ( Socket ) ) ;
234- RegisterType ( typeof ( TcpClient ) ) ;
235- RegisterType ( typeof ( TcpListener ) ) ;
236- RegisterType ( typeof ( UdpClient ) ) ;
202+ // RegisterType(typeof (NetworkStream));
203+ // RegisterType(typeof (Socket));
204+ // RegisterType(typeof (TcpClient));
205+ // RegisterType(typeof (TcpListener));
206+ // RegisterType(typeof (UdpClient));
237207 }
238208
239209 // DATA, XML, and LINQ
240210 {
241211 // System.Data
242- RegisterType ( typeof ( DataColumn ) ) ;
243- RegisterType ( typeof ( DataRow ) ) ;
244- RegisterType ( typeof ( DataSet ) ) ;
245- RegisterType ( typeof ( DataTable ) ) ;
246- RegisterType ( typeof ( DataView ) ) ;
212+ // RegisterType(typeof (DataColumn));
213+ // RegisterType(typeof (DataRow));
214+ // RegisterType(typeof (DataSet));
215+ // RegisterType(typeof (DataTable));
216+ // RegisterType(typeof (DataView));
247217
248218 // System.Data.Common
249- RegisterType ( typeof ( DbCommand ) ) ;
250- RegisterType ( typeof ( DbConnection ) ) ;
251- RegisterType ( typeof ( DbDataAdapter ) ) ;
252- RegisterType ( typeof ( DbDataReader ) ) ;
253- RegisterType ( typeof ( DbProviderFactory ) ) ;
219+ // RegisterType(typeof (DbCommand));
220+ // RegisterType(typeof (DbConnection));
221+ // RegisterType(typeof (DbDataAdapter));
222+ // RegisterType(typeof (DbDataReader));
223+ // RegisterType(typeof (DbProviderFactory));
254224
255225 // System.Data.SqlClient
256- RegisterType ( typeof ( SqlCommand ) ) ;
257- RegisterType ( typeof ( SqlConnection ) ) ;
258- RegisterType ( typeof ( SqlDataAdapter ) ) ;
259- RegisterType ( typeof ( SqlDataReader ) ) ;
226+ // RegisterType(typeof (SqlCommand));
227+ // RegisterType(typeof (SqlConnection));
228+ // RegisterType(typeof (SqlDataAdapter));
229+ // RegisterType(typeof (SqlDataReader));
260230
261231 // System.XML
262- RegisterType ( typeof ( XmlAttribute ) ) ;
263- RegisterType ( typeof ( XmlDocument ) ) ;
264- RegisterType ( typeof ( XmlElement ) ) ;
265- RegisterType ( typeof ( XmlNode ) ) ;
266- RegisterType ( typeof ( XmlReader ) ) ;
267- RegisterType ( typeof ( XmlWriter ) ) ;
232+ // RegisterType(typeof (XmlAttribute));
233+ // RegisterType(typeof (XmlDocument));
234+ // RegisterType(typeof (XmlElement));
235+ // RegisterType(typeof (XmlNode));
236+ // RegisterType(typeof (XmlReader));
237+ // RegisterType(typeof (XmlWriter));
268238
269239 // System.Xml.Linq
270- RegisterType ( typeof ( XAttribute ) ) ;
271- RegisterType ( typeof ( XDocument ) ) ;
272- RegisterType ( typeof ( XElement ) ) ;
273- RegisterType ( typeof ( XName ) ) ;
274- RegisterType ( typeof ( XNamespace ) ) ;
275- RegisterType ( typeof ( XNode ) ) ;
276- RegisterType ( typeof ( XText ) ) ;
240+ // RegisterType(typeof (XAttribute));
241+ // RegisterType(typeof (XDocument));
242+ // RegisterType(typeof (XElement));
243+ // RegisterType(typeof (XName));
244+ // RegisterType(typeof (XNamespace));
245+ // RegisterType(typeof (XNode));
246+ // RegisterType(typeof (XText));
277247
278248 // System.Xml.Schema
279- RegisterType ( typeof ( XmlSchema ) ) ;
280- RegisterType ( typeof ( XmlSchemaSet ) ) ;
281- RegisterType ( typeof ( XmlSchemaValidator ) ) ;
249+ // RegisterType(typeof (XmlSchema));
250+ // RegisterType(typeof (XmlSchemaSet));
251+ // RegisterType(typeof (XmlSchemaValidator));
282252
283253 // System.Xml.Serialization
284- RegisterType ( typeof ( XmlSerializer ) ) ;
254+ // RegisterType(typeof (XmlSerializer));
285255
286256 // System.Xml.XPath
287- RegisterType ( typeof ( XPathDocument ) ) ;
288- RegisterType ( typeof ( XPathExpression ) ) ;
289- RegisterType ( typeof ( XPathNavigator ) ) ;
257+ // RegisterType(typeof (XPathDocument));
258+ // RegisterType(typeof (XPathExpression));
259+ // RegisterType(typeof (XPathNavigator));
290260
291261 // System.Xml.Xsl
292- RegisterType ( typeof ( XslCompiledTransform ) ) ;
293- RegisterType ( typeof ( XsltArgumentList ) ) ;
262+ // RegisterType(typeof (XslCompiledTransform));
263+ // RegisterType(typeof (XsltArgumentList));
294264 }
295265
296266 // .NET Framework 4 and Extensions
297267 {
298268 // Core
299- RegisterType ( typeof ( SortedSet < > ) ) ;
300- RegisterType ( typeof ( ParallelEnumerable ) ) ;
301- RegisterType ( typeof ( LazyInitializer ) ) ;
302- RegisterType ( typeof ( SpinLock ) ) ;
303- RegisterType ( typeof ( Parallel ) ) ;
269+ // RegisterType(typeof (SortedSet<>));
270+ // RegisterType(typeof (ParallelEnumerable));
271+ // RegisterType(typeof (LazyInitializer));
272+ // RegisterType(typeof (SpinLock));
273+ // RegisterType(typeof (Parallel));
304274
305275 // System.Tuple
306276 RegisterType ( typeof ( Tuple ) ) ;
@@ -315,12 +285,12 @@ public void RegisterDefaultAlias()
315285 }
316286
317287 // NEW
318- RegisterType ( typeof ( CommandType ) ) ;
288+ // RegisterType(typeof (CommandType));
319289 RegisterType ( typeof ( Match ) ) ;
320290
321291 // Library
322- RegisterType ( typeof ( EvalManager ) ) ;
323- RegisterType ( typeof ( Eval ) ) ;
292+ // RegisterType(typeof (EvalManager));
293+ // RegisterType(typeof (Eval));
324294 }
325295 }
326296}
0 commit comments