Changeset 87


Ignore:
Timestamp:
Aug 29, 2017, 5:38:45 PM (7 years ago)
Author:
chronos
Message:
  • Added: New CSharp target.
  • Fixed: Use configured memory size in targets.
Location:
trunk
Files:
2 added
9 edited

Legend:

Unmodified
Added
Removed
  • trunk/Forms/UFormMain.lfm

    r83 r87  
    10931093    top = 72
    10941094    Bitmap = {
    1095       4C691B0000001000000010000000000000000000000000000000000000000000
     1095      4C691C0000001000000010000000000000000000000000000000000000000000
    10961096      0000000000000000000000000000000000000000000000000000000000000000
    10971097      000000000000000000000000000000000000000000FF000000FF000000FF0000
     
    19571957      FF0200000000000000000000000000000000000000000000000049D9FF0044D4
    19581958      FF0542D2FF8A40D1FFFF3ECFFFFF3CCDFFFF3ACBFFFF38C9FFB938C9FF140000
     1959      0000000000000000000000000000000000000000000000000000000000000000
     1960      000000000000EEF7EE1AD5CDD667D6CDD666EFF7EE1900000000000000000000
     1961      000000000000000000000000000000000000000000000000000000000000EEFF
     1962      EC0CE8E3E95DD0B3D2CCB07BB4FEB07CB4FED0B4D2CBE9E3E95BEDFFEC0B0000
     1963      00000000000000000000000000000000000000000000E0FFDD03ECEBEC41D8C2
     1964      D9B3B787BAF99A569FFF934A98FF934A98FF9B57A0FFB788BAF9D8C2DAB1ECEC
     1965      EC40DDFFD903000000000000000000000000E8E9E71CDFCFE094C097C3EEA060
     1966      A5FF944C99FF9F5EA3FFAD76B1FFAD75B1FF9F5DA3FF944C99FFA061A5FFC198
     1967      C3EDE0D0E192E8EBE81B0000000000000000DECEDF89AD76B1FF954E9AFF9751
     1968      9CFFBE92C1FFECDFEDFFFBF8FBFFFBF8FBFFEBDEECFFBD91C0FF97519CFF954E
     1969      9AFFAB72ACFFDCCBDB8600000000FFFFFF02D2B8D4A99B58A0FF954D9AFFBE91
     1970      C0FFFBF9FBFFFFFFFFFFF0E6F1FFF0E6F1FFFFFFFFFFFAF7FBFFB27EB3FF8A3C
     1971      89FF8F4389FFCEB3CCA9FFFFFF02FFFFFF02D2B8D4A99B58A0FF9E5CA2FFEADC
     1972      EBFFFFFFFFFFCFAFD1FFA161A5FFA262A6FFC9A5CAFFC59DC2FFA0609BFF944C
     1973      8EFF91478BFFCEB2CCA9FFFFFF02FFFFFF02D2B8D4A99B579FFFAB71AEFFF9F6
     1974      FAFFF2E9F3FFA364A7FF934A97FF8F448FFF8A3C86FF8D4187FFCAA6C7FFD3B5
     1975      D1FF9F5E9AFFCDB0CBA9FFFFFF02FFFFFF02D2B8D4A99B57A0FFAA70AEFFF9F4
     1976      F9FFF4ECF4FF9E5C9DFF802A74FF7D256EFF86367DFF8E4389FFC69FC3FFCEAD
     1977      CCFF9E5C99FFCDB0CBA9FFFFFF02FFFFFF02D2B8D4A99C58A1FF9C5AA1FFE6D5
     1978      E7FFFFFFFFFFCDACC7FF904681FF914782FFCAA6C3FFD0B0CEFF9F5F9AFF8E43
     1979      89FF90468AFFCEB2CCA9FFFFFF02FFFFFF02D2B9D4A999539BFF873681FFA66B
     1980      9CFFF5EFF4FFFFFFFFFFF4EDF3FFF5EEF3FFFFFFFFFFF6EFF4FF9F5F94FF7F29
     1981      73FF8C4086FFCFB3CCA9FFFFFF0200000000DDCDDD859F6096FF7A2168FF7920
     1982      67FFA26395FFDCC4D7FFF2EAF1FFF2EAF1FFDBC3D6FFA16294FF792067FF7A21
     1983      68FF9E5D93FFDCCADA820000000000000000E7EAE718DBC9D78AB483AAE98A3B
     1984      7AFF771D65FF7F2A6EFF8D417EFF8D417EFF7F296EFF771D65FF8A3C7AFFB484
     1985      ABE8DBCAD888E8ECE817000000000000000000000000F4FFFF01EDEFEE39D2B9
     1986      CDA9A86E9CF6822E71FF771C64FF771C65FF822F72FFA86F9DF5D3BACEA7EEEF
     1987      EE37F2FFFF01000000000000000000000000000000000000000000000000F6FF
     1988      FC08E8E3E753C8A6C1C49F5F92FB9F6093FBC9A8C2C2E8E4E852F6FFFC080000
     1989      0000000000000000000000000000000000000000000000000000000000000000
     1990      000000000000F3FFF515DCD3DA58DCD3DA57F3FFF61400000000000000000000
    19591991      0000000000000000000000000000
    19601992    }
  • trunk/LazFuck.lpi

    r82 r87  
    180180      </Item6>
    181181    </RequiredPackages>
    182     <Units Count="25">
     182    <Units Count="26">
    183183      <Unit0>
    184184        <Filename Value="LazFuck.lpr"/>
     
    322322        <IsPartOfProject Value="True"/>
    323323      </Unit24>
     324      <Unit25>
     325        <Filename Value="Target\UTargetCSharp.pas"/>
     326        <IsPartOfProject Value="True"/>
     327      </Unit25>
    324328    </Units>
    325329  </ProjectOptions>
  • trunk/Target/UTargetC.pas

    r86 r87  
    6868  AddLine('{');
    6969  Inc(Indent);
    70   AddLine('char Memory[30000];');
     70  AddLine('char Memory[' + IntToStr(MemorySize) + '];');
    7171  AddLine('int Pos;');
    7272  AddLine('char ReadChar;');
  • trunk/Target/UTargetDelphi.pas

    r86 r87  
    6060  AddLine('');
    6161  AddLine('var');
    62   AddLine('  Memory: array[0..30000] of Byte;');
     62  AddLine('  Memory: array[0..' + IntToStr(MemorySize) + '] of Byte;');
    6363  AddLine('  Pos: Integer;');
    6464  AddLine('  ReadChar: Char;');
  • trunk/Target/UTargetFPC.pas

    r86 r87  
    6262  AddLine('program ' + ProgramName + ';');
    6363  AddLine('var');
    64   AddLine('  Memory: array[0..30000] of Byte;');
     64  AddLine('  Memory: array[0..' + IntToStr(MemorySize) + '] of Byte;');
    6565  AddLine('  Pos: Integer;');
    6666  AddLine('  ReadChar: Char;');
  • trunk/Target/UTargetJava.pas

    r86 r87  
    7171  AddLine('char ReadChar;');
    7272  AddLine;
    73   AddLine('Memory = new char[30000];');
     73  AddLine('Memory = new char[' + IntToStr(MemorySize) + '];');
    7474  AddLine('Pos = 0;');
    7575  FProgramIndex := 0;
  • trunk/Target/UTargetPHP.pas

    r86 r87  
    6363  AddLine('<?php // ' + ProgramName);
    6464  AddLine('');
    65   AddLine('$Memory = str_repeat("\0", 30000);');
     65  AddLine('$Memory = str_repeat("\0", ' + IntToStr(MemorySize) + ');');
    6666  AddLine('$Position = 0;');
    6767  FProgramIndex := 0;
  • trunk/Target/UTargetPython.pas

    r86 r87  
    101101  AddLine('');
    102102  AddLine('import sys');
    103   AddLine('memory = [0] * 30000');
     103  AddLine('memory = [0] * ' + IntToStr(MemorySize));
    104104  AddLine('position = 0');
    105105  FProgramIndex := 0;
  • trunk/UCore.pas

    r82 r87  
    4949  // Targets
    5050  UTargetInterpretter, UTargetFPC, UBFTarget, UTargetJava, UTargetDelphi,
    51   UTargetPHP, UTargetC, UTargetPython;
     51  UTargetPHP, UTargetC, UTargetPython, UTargetCSharp;
    5252
    5353const
     
    6969  Targets.Add(TTargetJava.Create);
    7070  Targets.Add(TTargetPython.Create);
     71  Targets.Add(TTargetCSharp.Create);
    7172
    7273  {$IFDEF Linux}
Note: See TracChangeset for help on using the changeset viewer.