diff --git a/Configuration/GlobalAssemblyInfo.cs b/Configuration/GlobalAssemblyInfo.cs index fec9a7125..2e8ffb5a0 100644 --- a/Configuration/GlobalAssemblyInfo.cs +++ b/Configuration/GlobalAssemblyInfo.cs @@ -15,7 +15,7 @@ internal static class RevisionClass public const string Major = "3"; public const string Minor = "4"; public const string Build = "0"; - public const string Revision = "1685"; + public const string Revision = "1687"; public const string MainVersion = Major + "." + Minor; public const string FullVersion = Major + "." + Minor + "." + Build + "." + Revision; diff --git a/Configuration/Version.defs b/Configuration/Version.defs index 532dc1831..bdb884f1a 100644 --- a/Configuration/Version.defs +++ b/Configuration/Version.defs @@ -1,4 +1,4 @@ %COREVERSION%=0 -%REVISION%=1685 +%REVISION%=1687 %MINOR%=4 %MAJOR%=3 diff --git a/Parsers/PascalABCParserNewSaushkin/ABCPascal.cs b/Parsers/PascalABCParserNewSaushkin/ABCPascal.cs index 8d0e048aa..11a3ffa08 100644 --- a/Parsers/PascalABCParserNewSaushkin/ABCPascal.cs +++ b/Parsers/PascalABCParserNewSaushkin/ABCPascal.cs @@ -2,7 +2,7 @@ // This CSharp output file generated by Gardens Point LEX // Version: 1.1.3.301 // Machine: DESKTOP-A6LT9RI -// DateTime: 03.07.2018 13:20:55 +// DateTime: 03.07.2018 16:35:18 // UserName: ????????? // GPLEX input file // GPLEX frame file diff --git a/Parsers/PascalABCParserNewSaushkin/ABCPascal.y b/Parsers/PascalABCParserNewSaushkin/ABCPascal.y index 6d0a38227..3f24f2731 100644 --- a/Parsers/PascalABCParserNewSaushkin/ABCPascal.y +++ b/Parsers/PascalABCParserNewSaushkin/ABCPascal.y @@ -842,13 +842,13 @@ const_factor var i64 = $2 as int64_const; if (i64 != null && i64.val == (Int64)Int32.MaxValue + 1) { - $$ = new int32_const(Int32.MinValue); + $$ = new int32_const(Int32.MinValue,@$); break; } var ui64 = $2 as uint64_const; if (ui64 != null && ui64.val == (UInt64)Int64.MaxValue + 1) { - $$ = new int64_const(Int64.MinValue); + $$ = new int64_const(Int64.MinValue,@$); break; } if (ui64 != null && ui64.val > (UInt64)Int64.MaxValue + 1) @@ -1506,15 +1506,31 @@ object_type foreach (var prop in ccnt) { var td = prop.property_type; - if (prop.accessors.read_accessor != null && prop.accessors.read_accessor.pr != null) + var ra = prop.accessors.read_accessor; + if (ra != null && ra.pr != null) { - (prop.accessors.read_accessor.pr.proc_header as function_header).return_type = td; - cm.Add(prop.accessors.read_accessor.pr); + (ra.pr.proc_header as function_header).return_type = td; + cm.Add(ra.pr); + if (prop.attr == definition_attribute.Static) + { + ra.pr.proc_header.class_keyword = true; + procedure_attribute pa = new procedure_attribute(proc_attribute.attr_static); + pa.source_context = ra.pr.proc_header.source_context; + ra.pr.proc_header.proc_attributes = new procedure_attributes_list(pa); + } } - if (prop.accessors.write_accessor != null && prop.accessors.write_accessor.pr != null) + var wa = prop.accessors.write_accessor; + if (wa != null && wa.pr != null) { - prop.accessors.write_accessor.pr.proc_header.parameters.params_list[0].vars_type = td; - cm.Add(prop.accessors.write_accessor.pr); + wa.pr.proc_header.parameters.params_list[0].vars_type = td; + cm.Add(wa.pr); + if (prop.attr == definition_attribute.Static) + { + wa.pr.proc_header.class_keyword = true; + procedure_attribute pa = new procedure_attribute(proc_attribute.attr_static); + pa.source_context = wa.pr.proc_header.source_context; + wa.pr.proc_header.proc_attributes = new procedure_attributes_list(pa); + } } } if (cm.Count>0) @@ -3474,13 +3490,13 @@ factor var i64 = $2 as int64_const; if (i64 != null && i64.val == (Int64)Int32.MaxValue + 1) { - $$ = new int32_const(Int32.MinValue); + $$ = new int32_const(Int32.MinValue,@$); break; } var ui64 = $2 as uint64_const; if (ui64 != null && ui64.val == (UInt64)Int64.MaxValue + 1) { - $$ = new int64_const(Int64.MinValue); + $$ = new int64_const(Int64.MinValue,@$); break; } if (ui64 != null && ui64.val > (UInt64)Int64.MaxValue + 1) diff --git a/Parsers/PascalABCParserNewSaushkin/ABCPascalYacc.cs b/Parsers/PascalABCParserNewSaushkin/ABCPascalYacc.cs index 111282808..6aba9db97 100644 --- a/Parsers/PascalABCParserNewSaushkin/ABCPascalYacc.cs +++ b/Parsers/PascalABCParserNewSaushkin/ABCPascalYacc.cs @@ -2,7 +2,7 @@ // GPPG version 1.3.6 // Machine: DESKTOP-A6LT9RI -// DateTime: 03.07.2018 13:20:56 +// DateTime: 03.07.2018 16:35:18 // UserName: ????????? // Input file @@ -3168,13 +3168,13 @@ public partial class GPPGParser: ShiftReduceParser (UInt64)Int64.MaxValue + 1) @@ -3792,15 +3792,31 @@ public partial class GPPGParser: ShiftReduceParser0) @@ -5661,13 +5677,13 @@ public partial class GPPGParser: ShiftReduceParser (UInt64)Int64.MaxValue + 1) diff --git a/ReleaseGenerators/PascalABCNET_version.nsh b/ReleaseGenerators/PascalABCNET_version.nsh index 3a2fe28f1..68c949fb8 100644 --- a/ReleaseGenerators/PascalABCNET_version.nsh +++ b/ReleaseGenerators/PascalABCNET_version.nsh @@ -1 +1 @@ -!define VERSION '3.4.0.1685' +!define VERSION '3.4.0.1687' diff --git a/TestSuite/static_ext_prop.pas b/TestSuite/static_ext_prop.pas new file mode 100644 index 000000000..4b749b2f7 --- /dev/null +++ b/TestSuite/static_ext_prop.pas @@ -0,0 +1,14 @@ +type + t1=class + class v: byte; + class property a: byte read v + write + begin + v := value; + end; + end; + +begin + t1.a := 1; + Assert(t1.a=1); +end. \ No newline at end of file