1 write to _tc
Microsoft.CodeAnalysis.CSharp (1)
Utilities\ValueSetFactory.NumericValueSet.cs (1)
51_tc = tc;
51 references to _tc
Microsoft.CodeAnalysis.CSharp (51)
Utilities\ValueSetFactory.NumericValueSet.cs (51)
64var gz = new NumericValueSetFactory<T>(_tc).Related(BinaryOperatorKind.GreaterThanOrEqual, _tc.Zero); 67return _tc.ToConstantValue(t._intervals[0].first); 68return _tc.ToConstantValue(this._intervals[this._intervals.Length - 1].last); 78return _intervals.Length > 0 && _tc.Related(relation, _intervals[0].first, value); 81return _intervals.Length > 0 && _tc.Related(relation, _intervals[_intervals.Length - 1].last, value); 96return _tc.Related(GreaterThanOrEqual, value, _intervals[lastIntervalIndex].first) && _tc.Related(LessThanOrEqual, value, _intervals[lastIntervalIndex].last); 99if (_tc.Related(LessThanOrEqual, value, _intervals[midIndex].last)) 107bool IValueSet.Any(BinaryOperatorKind relation, ConstantValue value) => value.IsBad || Any(relation, _tc.FromConstantValue(value)); 118return _tc.Related(relation, _intervals[_intervals.Length - 1].last, value); 121return _tc.Related(relation, _intervals[0].first, value); 123return _intervals.Length == 1 && _tc.Related(Equal, _intervals[0].first, value) && _tc.Related(Equal, _intervals[0].last, value); 129bool IValueSet.All(BinaryOperatorKind relation, ConstantValue value) => !value.IsBad && All(relation, _tc.FromConstantValue(value)); 134return AllValues(_tc); 139if (_tc.Related(LessThan, _tc.MinValue, _intervals[0].first)) 141builder.Add((_tc.MinValue, _tc.Prev(_intervals[0].first))); 148builder.Add((_tc.Next(_intervals[i].last), _tc.Prev(_intervals[i + 1].first))); 152if (_tc.Related(LessThan, _intervals[lastIndex].last, _tc.MaxValue)) 154builder.Add((_tc.Next(_intervals[lastIndex].last), _tc.MaxValue)); 157return new NumericValueSet<T>(builder.ToImmutableAndFree(), _tc); 165Debug.Assert(this._tc.GetType() == other._tc.GetType()); 176if (_tc.Related(LessThan, leftInterval.last, rightInterval.first)) 180else if (_tc.Related(LessThan, rightInterval.last, leftInterval.first)) 186Add(builder, Max(leftInterval.first, rightInterval.first, _tc), Min(leftInterval.last, rightInterval.last, _tc), _tc); 187if (_tc.Related(LessThan, leftInterval.last, rightInterval.last)) 191else if (_tc.Related(LessThan, rightInterval.last, leftInterval.last)) 203return new NumericValueSet<T>(builder.ToImmutableAndFree(), _tc); 242Debug.Assert(this._tc.GetType() == other._tc.GetType()); 253if (_tc.Related(LessThan, leftInterval.last, rightInterval.first)) 255Add(builder, leftInterval.first, leftInterval.last, _tc); 258else if (_tc.Related(LessThan, rightInterval.last, leftInterval.first)) 260Add(builder, rightInterval.first, rightInterval.last, _tc); 265Add(builder, Min(leftInterval.first, rightInterval.first, _tc), Max(leftInterval.last, rightInterval.last, _tc), _tc); 274Add(builder, leftInterval.first, leftInterval.last, _tc); 281Add(builder, rightInterval.first, rightInterval.last, _tc); 285return new NumericValueSet<T>(builder.ToImmutableAndFree(), _tc); 317return string.Join(",", this._intervals.Select(p => $"[{_tc.ToString(p.first)}..{_tc.ToString(p.last)}]"));