This commit is contained in:
Бондарев Иван 2018-12-31 11:34:32 +01:00
parent c1fbe7a447
commit 105e87b0df
2 changed files with 10 additions and 2 deletions

View file

@ -407,7 +407,8 @@ namespace CodeCompletion
(t is ArrayScope && tmp_ts2.IsArray && t.Rank == tmp_ts2.Rank) ||
( tmp_ts2 is ArrayScope && t.IsArray && tmp_ts2.Rank == t.Rank) ||
(t is TemplateParameterScope || t is UnknownScope) ||
t is FileScope && tmp_ts2 is FileScope
t is FileScope && tmp_ts2 is FileScope &&
((t as FileScope).elementType == null) == ((tmp_ts2 as FileScope).elementType == null)
)
{
lst.AddRange(extension_methods[t]);
@ -441,7 +442,8 @@ namespace CodeCompletion
if (t.GenericTypeDefinition == int_ts2.GenericTypeDefinition || t.IsEqual(int_ts2) ||
(t is ArrayScope && int_ts2.IsArray && t.Rank == int_ts2.Rank) ||
(int_ts2 is ArrayScope && t.IsArray && int_ts2.Rank == t.Rank) ||
t is FileScope && int_ts2 is FileScope)
t is FileScope && int_ts2 is FileScope &&
((t as FileScope).elementType == null) == ((int_ts2 as FileScope).elementType == null))
{
lst.AddRange(extension_methods[t]);
//break;

View file

@ -0,0 +1,6 @@
begin
var f: file of integer;
f.Read{@(расширение file of T) function PABCExtensions.Read<T>(): T;@}();
var f2: file;
f2.Read{@@}();
end.