⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sys.p2crc

📁 把pascal程序转成C语言程序 把pascal程序转成C语言程序
💻 P2CRC
📖 第 1 页 / 共 5 页
字号:
				# default=P_trimname for Oregon/Berk, else 0LiteralFiles			# 0=nameless rewrite(f) generates a temp file				# 1=nameless rewrite(f) uses "f" as file name				# 2=like 1 only if f appeared in "program" stmt				# default=2 for Berkeley, else 0.LiteralFile			# A file variable which should be treated asLiteralFile			# if LiteralFiles=1.  If LiteralFiles=2, filesLiteralFile			# in program header are added to this list.StructFiles			# 1="file of x" produces a struct with buffer				#   and file-name included.				# 0 or default=use native FILE *'s, with				#   extra variables to hold buffer and name.StructFile			# A file variable which should be treated asStructFile			# if StructFiles=1.FullStrWrite                    # 1=full implementation of strwrite(s,i,j,...)                                # 0=ignore "j" variable and other issues                                # default=assign "j", assume not mid-string                                # 2=like default, but issue a warningFullStrRead                     # 1 or default=full impl of strread using "%n"                                # 0=fake the value of "j"                                # 2=like default, but issue a warningSetBits                         # Number of bits to use in each "long" of a set                                # default=LongSize if defined, else 32DefaultSetSize                  # Default size of un-typed set constants;                                # default default=256 for VAX, else 8192SmallSetConst                   # 0=write small-set literals like "1<<2|1<<4"                                # 1=write them like "0x14"                                # 2=write them like "20"                                # -1=do not use small-sets at all                                # default=-1 if SetBitsName defined, else 1BigSetConst                     # (analogous to SmallSetConst for big sets)LeLeRange                       # 1=write "j in [1..10]" as "1<=j && j<=10"                                # 0 or default=write ... as "j>=1 && j<=10"UnsignedTrick                   # 1 or default=write "(unsigned)i <= 10"                                # 0=leave "i >= 0 && i <= 10" aloneUseIsAlpha                      # 1 or default=use "isalpha", "isdigit", etc.                                # 0=use plain comparisonsUseIsSpace                      # 1=convert "c==' '" to "isspace(c)"                                # 0 or default=leave it aloneUseStrncmp			# 1=use strncmp to compare packed array of char				# 0=use memcmp, same as for all other arrays				# default=1# NAMING CONVENTIONSCodeFileName      %Rs.c         # Name of .c output file for a program,                                # %s=input file name.ModuleFileName    %_S.c         # Name of .c output file for a module,                                # %s=input file name, %S=module name.HeaderFileName    %_S.h         # Name of .h output file for a module,                                # %s=input file name, %S=module name.HeaderFileName2                 # If defined, different format to use when                                # generating #include's, otherwise same.                                # May be quoted as in IncludeFrom.SelfIncludeName			# Format to apply after HeaderFileName to use                                # when a module includes its own header file.LogFileName       %RS.log       # Name of log file name for -V mode.                                # %s=input file name, %S=output file name.IncludeFileName                 # Format for translating Pascal include-file				# names.IncludeOutFileName  %Rs.c       # Name of .c output file for an include                                # file generated in ExpandIncludes=0 mode.SymCase                         # 1 or default=preserve case of Pascal idents,                                # 0=convert all Pascal idents to lower caseSymbolFormat                    # Format for C identifiers derived from                                # Pascal ones; default=%s.  The following                                # specific formats override this one.                                # %s=original Pascal identifier,                                # %S=name of parent module or procedure.ConstFormat                     # Format for #define names derived from                                # Pascal consts.  (Often used: %^s)ModuleFormat                    # Format for program and module names.FunctionFormat			# Format for procedure and function names.VarFormat			# Format for variable names.TypeFormat			# Format for typedef names.FieldFormat			# Format for fields of records; %S=record type.EnumFormat			# Format for enumeration constants;				# %s=enum type name.  If not specified,				# default is ConstFormat, else SymbolFormat.ReturnValueName   Result        # Return value holding variable; [%s=func name]UnitInitName      _%s_init      # Turbo Pascal unit initializer; %s=unit nameHSymbolName       %s_H          # Name of "_H" symbol, if any; %s=unit nameGSymbolName       %s_G          # Name of "_G" symbol; [%s=unit name]StringMaxName     MAX_%s        # VAR STRING hidden variable; %s=param nameArrayMinName	  %s_LOW	# Lower bound hidden variable; %s=param nameArrayMaxName	  %s_HIGH	# Upper bound hidden variable; %s=param nameCopyParName       %s_           # Alternate name for parameter %sStaticLinkName    LINK          # Static link parameter name; [%s=func name]LocalVarsStruct   LOC_%s        # Name of struct type for locals; %s=func nameLocalVarsName     V             # Name of struct var for locals; [%s=func name]FwdStructName     %s            # Name of forward-used structs; %s=type name                                # (may simply be %s if you don't mind confusion)EnumListName      %s_NAMES      # Name of array to hold names for enum %sUnionName         UU            # Name of variant unionUnionPartName     %s            # Name of variant element; %s=tag value nameFakeStructName    _REC_%s	# Name of "temporary" structs; %s=base nameLabelName         _L%s          # Name of GOTO label; %s=label nameLabelVarName      _JL%s		# Name of GOTO label jmp_buf variable; %s=labelTempName          TEMP%s        # Name of general temporary vars; %s=unique idDummyName         DUMMY%s       # Name of throwaway "dummy" vars; %s=unique idWithName          WITH%s        # Name of WITH statement temp ptr; %s=unique idForName           FORLIM%s      # Name of FOR statement temp limit; %s=unique idPtrName           PTR%s         # Name of NIL-checking temp ptr; %s=unique idStringName        STR%s         # Name of temporary string vars; %s=unique idSetName           SET%s         # Name of temporary set vars; %s=unique idFNVarName         %s_NAME       # Name of file-name vars; %s=file varFNSizeName        _FNSIZE       # Maximum length of file name (macro or integer)TagStructs                      # 1=Use FakeStructName for most unnamed records				# 0 or default=only for arrays/files of recordsAlternateName1    %s_           # Way to produce a second C symbol for a Pascal                                # symbol, where original symbol was %s.  Default                                # is to use AlternateName with %d=1.AlternateName2                  # A second alternate for %s.AlternateName                   # A %d'th name for %s.  %s and %d may appear in                                # either order.  Default is %d applications of                                # AlternateName1.ExportSymbol                    # Name of exported symbol %s.  E.g.: "P_%s"                                # Default=%s, i.e., don't mess with the name.                                # %s is Pascal symbol name; %S is module name.Export_Symbol                   # Exported-symbol format to be used when the                                # symbol %s contains an '_'.  Default=use                                # ExportSymbol format for every symbol.Alias                           # Name of external proc or var; default="%s".                                # If does not contain a "%s", this simply                                # renames the next defined symbol of any kind.Synonym				# Format:  Synonym name = newnameSynonym				# Treat the word "name" in the input fileSynonym				# exactly the same as the keyword or identifierSynonym				# "newname".  If "newname" is omitted, ignoreSynonym				# the word "name" in the input.  For example:Synonym				# "Synonym andthen = and" creates a keyword;Synonym				# "Synonym allocmem = getmem" simulates aSynonym				# built-in function "allocmem" which acts likeSynonym				# Turbo's "getmem"; "Synonym segment" ignoresSynonym				# the word "segment" in the input.NameOf                          # Format:  NameOf name = newnameNameOf                          # Rename the specified symbol.  The name mayNameOf                          # be of the form "modulename.name" orNameOf                          # "procname.name"; otherwise, all usages ofNameOf                          # the symbol are renamed.VarMacro                        # Format:  VarMacro varname = C-expressionVarMacro                        # Must come before the declaration of variableVarMacro                        # "varname".  Causes all references to theVarMacro                        # variable to use the C expression instead.VarMacro                        # In the expr, all C operators are supported;VarMacro                        # all identifier names are used verbatim.VarMacro                        # Also works for Turbo Pascal typed-constants.VarMacro                        # Suppresses declaration of variable unlessVarMacro                        # "varname" appears in the C expression.VarMacro                        # Simple algebra is used for assignments toVarMacro                        # vars with expr definitions: if X -> 2*V+1,VarMacro                        # then "X:=Y" translates to "V=(Y-1)/2".ConstMacro                      # Analogous to VarMacro, but for constants andConstMacro                      # enumeration constants.  In an enum constant,ConstMacro                      # if the C-expression is a single name theConstMacro                      # result is equivalent to Alias or NameOf.FieldMacro                      # Format:  FieldMacro rec.field = C-expressionFieldMacro                      # where "rec" is a record type name whichFieldMacro                      # also appears in the C-expression.  ForFieldMacro                      # example: FieldMacro obj.foo = bar(obj) causesFieldMacro                      # the field "foo" of record type "obj" to be FieldMacro                      # referenced through the function or macroFieldMacro                      # "bar", rather than using dot notation.FuncMacro                       # Format:  FuncMacro foo(a,b,c) = C-expressionFuncMacro                       # where "a", "b", "c" are arbitrary arg namesFuncMacro                       # also appearing in the C-expression.  "Foo"FuncMacro                       # is a procedure or function defined or to beFuncMacro                       # defined in the code, or predefined in Pascal.FuncMacro                       # E.g.: FuncMacro PtInRect(p,r) = PtInRect(p,&r)FuncMacro                       # causes "r" to be treated as a VAR param evenFuncMacro                       # though otherwise it would be passed by value.WarnMacros                      # 1=warn if Var/Const/Field/FuncMacro not used                                # 0 or default=don't care.SpecialMalloc                   # Format:  SpecialMalloc x.y.z = funcnameSpecialMalloc                   # where x is a type name, and y and z areSpecialMalloc                   # optional variant tags for records.  TheSpecialMalloc                   # statement "new(p,y,z)" where p is a pointerSpecialMalloc                   # to x is converted to p = funcname().SpecialFree                     # Like SpecialMalloc, but defines a specialSpecialFree                     # function for freeing things of a given type.SpecialSizeOf                   # Like SpecialMalloc, but defines a name orSpecialSizeOf                   # other integer-valued C expression which isSpecialSizeOf                   # the size of an object of the given type.AvoidName         getc          # If any of these names appear in the code,AvoidName         putc          # use an alternate name so as to avoidAvoidName         getchar       # library conflicts.AvoidName         putcharAvoidName         feof          # These are typically macro names whose useAvoidName         ferror        # would be disasterous under anyAvoidName         clearerr      # circumstances.AvoidName         filenoAvoidName         BUFSIZ    NULL    EOFAvoidName         stdin     stdout  stderrAvoidName         true false assertAvoidName         Anyptr Void Char PP PVAvoidName         Signed Const Volatile Register Static Local InlineAvoidName         cdecl far near hugeAvoidName         isalpha isupper islower isdigit isxdigit isspace ispunctAvoidName         isalnum isprint isgraph iscntrl isascii toasciiAvoidName         toupper tolowerAvoidName	  LINK SEXTAvoidGlobalName   fopen         # These names should be avoided in globalAvoidGlobalName   fclose        # contexts, but they are okay as local names.AvoidGlobalName   fseekAvoidGlobalName   exit      mainAvoidGlobalName   strcpy    strcatAvoidGlobalName   printf    fprintf sprintfAvoidGlobalName   scanf     fscanf  sscanfAvoidGlobalName   malloc    realloc freeAvoidGlobalName   y0 y1 yn j0 j1 jn    # from math.h -- urghhh!                                # ... we should define lots more of these!WarnName                        # A similar list of names to leave alone, butWarnName                        # generate warnings for if they are defined.WarnNames                       # 1=All vars, consts, types, procs, fields                                # 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -