{
Normal = 0,
Probing = 1,
- IgnoreAccessibility = 2
+ IgnoreAccessibility = 2,
+ IgnoreStaticUsing = 1 << 10
}
//
if (rc.HasSet (ResolveContext.Options.BaseInitializer))
flags |= ResolveContext.Options.BaseInitializer;
+
+ if (rc.HasSet (ResolveContext.Options.QueryClauseScope))
+ flags |= ResolveContext.Options.QueryClauseScope;
}
public ExceptionStatement CurrentTryBlock { get; set; }
NameOfScope = 1 << 17,
+ QueryClauseScope = 1 << 18,
+
///
/// Indicates the current context is in probing mode, no errors are reported.
///
return da;
}
+ public Dictionary<Statement, List<DefiniteAssignmentBitSet>> CopyLabelStack ()
+ {
+ if (LabelStack == null)
+ return null;
+
+ var dest = new Dictionary<Statement, List<DefiniteAssignmentBitSet>> ();
+ foreach (var entry in LabelStack) {
+ dest.Add (entry.Key, new List<DefiniteAssignmentBitSet> (entry.Value));
+ }
+
+ return dest;
+ }
+
public bool IsDefinitelyAssigned (VariableInfo variable)
{
return variable.IsAssigned (DefiniteAssignment);
return variable.IsStructFieldAssigned (DefiniteAssignment, name);
}
+ public void SetLabelStack (Dictionary<Statement, List<DefiniteAssignmentBitSet>> labelStack)
+ {
+ LabelStack = labelStack;
+ }
+
public void SetVariableAssigned (VariableInfo variable, bool generatedAssignment = false)
{
variable.SetAssigned (DefiniteAssignment, generatedAssignment);
}
+ public void SetVariableAssigned (VariableInfo variable, DefiniteAssignmentBitSet da)
+ {
+ variable.SetAssigned (da, false);
+ }
+
public void SetStructFieldAssigned (VariableInfo variable, string name)
{
variable.SetStructFieldAssigned (DefiniteAssignment, name);
if (all_source_files == null) {
all_source_files = new Dictionary<string, SourceFile> ();
foreach (var source in SourceFiles)
- all_source_files[source.FullPathName] = source;
+ all_source_files[source.OriginalFullPathName] = source;
}
string path;
if (!Path.IsPathRooted (name)) {
var loc = comp_unit.SourceFile;
- string root = Path.GetDirectoryName (loc.FullPathName);
+ string root = Path.GetDirectoryName (loc.OriginalFullPathName);
path = Path.GetFullPath (Path.Combine (root, name));
var dir = Path.GetDirectoryName (loc.Name);
if (!string.IsNullOrEmpty (dir))