ParserFlags.st
changeset 1702 e69b1ee7a17a
parent 1701 d122f5efa601
child 1703 97b2baf97611
equal deleted inserted replaced
1701:d122f5efa601 1702:e69b1ee7a17a
    30 		allowDomainVariables allowArrayIndexSyntaxExtension
    30 		allowDomainVariables allowArrayIndexSyntaxExtension
    31 		allowReservedWordsAsSelectors allowVariableReferences
    31 		allowReservedWordsAsSelectors allowVariableReferences
    32 		allowLazyValueExtension allowFixedPointLiterals
    32 		allowLazyValueExtension allowFixedPointLiterals
    33 		allowExtendedSTXSyntax allowVisualAgeESSymbolLiterals
    33 		allowExtendedSTXSyntax allowVisualAgeESSymbolLiterals
    34 		allowExtensionsToPrivateClasses allowSqueakPrimitives
    34 		allowExtensionsToPrivateClasses allowSqueakPrimitives
    35 		allowVisualAgePrimitives allowSTVPrimitives arraysAreImmutable
    35 		allowVisualAgePrimitives allowSTVPrimitives allowSTVExtensions
    36 		stringsAreImmutable implicitSelfSends stcKeepCIntermediate
    36 		arraysAreImmutable stringsAreImmutable implicitSelfSends
    37 		stcKeepOIntermediate stcKeepSTIntermediate stcModulePath
    37 		stcKeepCIntermediate stcKeepOIntermediate stcKeepSTIntermediate
    38 		stcCompilation stcCompilationIncludes stcCompilationDefines
    38 		stcModulePath stcCompilation stcCompilationIncludes
    39 		stcCompilationOptions stcPath ccCompilationOptions ccPath
    39 		stcCompilationDefines stcCompilationOptions stcPath
    40 		linkArgs linkCommand libPath searchedLibraries'
    40 		ccCompilationOptions ccPath linkArgs linkCommand libPath
       
    41 		searchedLibraries'
    41 	classVariableNames:'WarnST80Directives WarnUnusedVars WarnUndeclared
    42 	classVariableNames:'WarnST80Directives WarnUnusedVars WarnUndeclared
    42 		WarnAboutWrongVariableNames WarnAboutBadComments
    43 		WarnAboutWrongVariableNames WarnAboutBadComments
    43 		WarnAboutVariableNameConventions WarnSTXSpecials
    44 		WarnAboutVariableNameConventions WarnSTXSpecials
    44 		WarnOldStyleAssignment WarnUnderscoreInIdentifier
    45 		WarnOldStyleAssignment WarnUnderscoreInIdentifier
    45 		WarnCommonMistakes WarnPossibleIncompatibilities
    46 		WarnCommonMistakes WarnPossibleIncompatibilities
    53 		AllowDolphinExtensions AllowOldStyleAssignment
    54 		AllowDolphinExtensions AllowOldStyleAssignment
    54 		AllowExtendedBinarySelectors AllowExtendedSTXSyntax
    55 		AllowExtendedBinarySelectors AllowExtendedSTXSyntax
    55 		AllowFixedPointLiterals AllowLiteralNameSpaceSymbols
    56 		AllowFixedPointLiterals AllowLiteralNameSpaceSymbols
    56 		AllowVisualAgeESSymbolLiterals AllowExtensionsToPrivateClasses
    57 		AllowVisualAgeESSymbolLiterals AllowExtensionsToPrivateClasses
    57 		AllowSqueakPrimitives AllowVisualAgePrimitives AllowSTVPrimitives
    58 		AllowSqueakPrimitives AllowVisualAgePrimitives AllowSTVPrimitives
    58 		ArraysAreImmutable StringsAreImmutable ImplicitSelfSends
    59 		AllowSTVExtensions ArraysAreImmutable StringsAreImmutable
    59 		STCModulePath STCKeepCIntermediate STCKeepOIntermediate
    60 		ImplicitSelfSends STCModulePath STCKeepCIntermediate
    60 		STCKeepSTIntermediate STCCompilation STCCompilationIncludes
    61 		STCKeepOIntermediate STCKeepSTIntermediate STCCompilation
    61 		STCCompilationDefines STCCompilationOptions STCPath
    62 		STCCompilationIncludes STCCompilationDefines
    62 		CCCompilationOptions CCPath LinkArgs LinkCommand LibPath
    63 		STCCompilationOptions STCPath CCCompilationOptions CCPath
    63 		SearchedLibraries'
    64 		LinkArgs LinkCommand LibPath SearchedLibraries'
    64 	poolDictionaries:''
    65 	poolDictionaries:''
    65 	category:'System-Compiler'
    66 	category:'System-Compiler'
    66 !
    67 !
    67 
    68 
    68 !ParserFlags class methodsFor:'documentation'!
    69 !ParserFlags class methodsFor:'documentation'!
   477     AllowReservedWordsAsSelectors := aBoolean.
   478     AllowReservedWordsAsSelectors := aBoolean.
   478 
   479 
   479     "
   480     "
   480      self allowReservedWordsAsSelectors:true
   481      self allowReservedWordsAsSelectors:true
   481      self allowReservedWordsAsSelectors:false
   482      self allowReservedWordsAsSelectors:false
       
   483     "
       
   484 !
       
   485 
       
   486 allowSTVExtensions
       
   487     "return true, if support for ST/V syntax extensions is enabled."
       
   488 
       
   489     ^ AllowSTVExtensions
       
   490 !
       
   491 
       
   492 allowSTVExtensions:aBoolean
       
   493     "this allows turning on/off support for ST/V extensions:
       
   494      If you want to fileIn ST/V classes, enable this with:
       
   495         Compiler allowSTVComputedArrays:true"
       
   496 
       
   497     AllowSTVExtensions := aBoolean.
       
   498 
       
   499     "
       
   500      self allowSTVExtensions:true
       
   501      self allowSTVExtensions:false
   482     "
   502     "
   483 !
   503 !
   484 
   504 
   485 allowSTVPrimitives
   505 allowSTVPrimitives
   486     "return true, if support for ST/V primitives is enabled."
   506     "return true, if support for ST/V primitives is enabled."
   809 
   829 
   810     AllowReservedWordsAsSelectors := false.
   830     AllowReservedWordsAsSelectors := false.
   811     AllowUnderscoreInIdentifier := true.        "/ underscores in identifiers
   831     AllowUnderscoreInIdentifier := true.        "/ underscores in identifiers
   812     AllowDollarInIdentifier := false.           "/ st80-vms dollars in identifiers
   832     AllowDollarInIdentifier := false.           "/ st80-vms dollars in identifiers
   813     AllowOldStyleAssignment := true.            "/ st80 underscore as assignment
   833     AllowOldStyleAssignment := true.            "/ st80 underscore as assignment
   814     AllowSqueakExtensions := false.             "/ squeak computed array
       
   815     AllowDolphinExtensions := false.            "/ dolphin computed literal
   834     AllowDolphinExtensions := false.            "/ dolphin computed literal
   816     AllowQualifiedNames := false.               "/ vw3 qualified names
   835     AllowQualifiedNames := false.               "/ vw3 qualified names
   817     AllowExtendedBinarySelectors := false.      "/ vw5.4 extended binary selectors (plus/minus, center-dot etc.)
   836     AllowExtendedBinarySelectors := false.      "/ vw5.4 extended binary selectors (plus/minus, center-dot etc.)
   818     AllowLiteralNameSpaceSymbols := true.       "/ st/x literal nameSpace-symbols (#foo::bar)
   837     AllowLiteralNameSpaceSymbols := true.       "/ st/x literal nameSpace-symbols (#foo::bar)
   819     AllowArrayIndexSyntaxExtension := false.
   838     AllowArrayIndexSyntaxExtension := false.
   827     AllowFixedPointLiterals := false.
   846     AllowFixedPointLiterals := false.
   828     AllowExtendedSTXSyntax := false.
   847     AllowExtendedSTXSyntax := false.
   829     AllowVisualAgeESSymbolLiterals := false.
   848     AllowVisualAgeESSymbolLiterals := false.
   830     AllowExtensionsToPrivateClasses := true.
   849     AllowExtensionsToPrivateClasses := true.
   831     AllowVisualAgePrimitives := false.
   850     AllowVisualAgePrimitives := false.
       
   851     AllowSqueakExtensions := false.             "/ squeak computed array
   832     AllowSqueakPrimitives := false.
   852     AllowSqueakPrimitives := false.
   833     AllowSTVPrimitives := false.
   853     AllowSTVPrimitives := false.                "/ number-sign syntax
       
   854     AllowSTVExtensions := false.
   834 
   855 
   835     ArraysAreImmutable := false.                "/ no longer care for ST-80 compatibility
   856     ArraysAreImmutable := false.                "/ no longer care for ST-80 compatibility
   836     StringsAreImmutable := false.               "/ no longer care for ST-80 compatibility
   857     StringsAreImmutable := false.               "/ no longer care for ST-80 compatibility
   837     ImplicitSelfSends := false.
   858     ImplicitSelfSends := false.
   838 
   859 
  1405     allowVisualAgeESSymbolLiterals := AllowVisualAgeESSymbolLiterals.
  1426     allowVisualAgeESSymbolLiterals := AllowVisualAgeESSymbolLiterals.
  1406     allowExtensionsToPrivateClasses := AllowExtensionsToPrivateClasses.
  1427     allowExtensionsToPrivateClasses := AllowExtensionsToPrivateClasses.
  1407     allowVisualAgePrimitives := AllowVisualAgePrimitives.
  1428     allowVisualAgePrimitives := AllowVisualAgePrimitives.
  1408     allowSqueakPrimitives := AllowSqueakPrimitives.
  1429     allowSqueakPrimitives := AllowSqueakPrimitives.
  1409     allowSTVPrimitives := AllowSTVPrimitives.
  1430     allowSTVPrimitives := AllowSTVPrimitives.
       
  1431     allowSTVExtensions := AllowSTVExtensions.
  1410 
  1432 
  1411     arraysAreImmutable := ArraysAreImmutable ? true.
  1433     arraysAreImmutable := ArraysAreImmutable ? true.
  1412     stringsAreImmutable := StringsAreImmutable ? true.
  1434     stringsAreImmutable := StringsAreImmutable ? true.
  1413     implicitSelfSends := ImplicitSelfSends ? false.
  1435     implicitSelfSends := ImplicitSelfSends ? false.
  1414 
  1436 
  1435 ! !
  1457 ! !
  1436 
  1458 
  1437 !ParserFlags class methodsFor:'documentation'!
  1459 !ParserFlags class methodsFor:'documentation'!
  1438 
  1460 
  1439 version
  1461 version
  1440     ^ '$Header: /cvs/stx/stx/libcomp/ParserFlags.st,v 1.14 2006-03-08 12:11:04 cg Exp $'
  1462     ^ '$Header: /cvs/stx/stx/libcomp/ParserFlags.st,v 1.15 2006-03-08 12:23:28 cg Exp $'
  1441 ! !
  1463 ! !
  1442 
  1464 
  1443 ParserFlags initialize!
  1465 ParserFlags initialize!