author | Claus Gittinger <cg@exept.de> |
Mon, 07 Dec 2009 20:41:07 +0100 | |
changeset 2306 | 9fc61be5ae18 |
parent 2219 | d6816a6d0e86 |
child 2307 | 5284fcab4bb7 |
permissions | -rw-r--r-- |
1634 | 1 |
" |
2 |
COPYRIGHT (c) 1989 by Claus Gittinger |
|
3 |
COPYRIGHT (c) 2005 by eXept Software AG |
|
4 |
All Rights Reserved |
|
5 |
||
6 |
This software is furnished under a license and may be used |
|
7 |
only in accordance with the terms of that license and with the |
|
8 |
inclusion of the above copyright notice. This software may not |
|
9 |
be provided or otherwise made available to, or used by, any |
|
10 |
other person. No title to or ownership of the software is |
|
11 |
hereby transferred. |
|
12 |
" |
|
13 |
"{ Package: 'stx:libcomp' }" |
|
14 |
||
15 |
Object subclass:#ParserFlags |
|
1898 | 16 |
instanceVariableNames:'warnings warnUnusedVars warnUndeclared warnST80Directives |
17 |
warnSTXHereExtensionUsed warnSTXSpecialComment |
|
18 |
warnUnderscoreInIdentifier warnOldStyleAssignment |
|
19 |
warnCommonMistakes warnSTXNameSpaceUse |
|
20 |
warnPossibleIncompatibilities warnDollarInIdentifier |
|
21 |
warnHiddenVariables warnAboutVariableNameConventions |
|
22 |
warnAboutWrongVariableNames warnAboutBadComments |
|
23 |
warnInconsistentReturnValues |
|
24 |
warnAboutNonLowercaseLocalVariableNames |
|
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
25 |
warnAboutPossibleSTCCompilationProblems |
2121 | 26 |
warnAboutReferenceToPrivateClass warnAboutShortLocalVariableNames |
27 |
warnAboutPossiblyUnimplementedSelectors |
|
28 |
allowLiteralNameSpaceSymbols allowUnderscoreInIdentifier |
|
29 |
allowDollarInIdentifier allowOldStyleAssignment |
|
30 |
allowSqueakExtensions allowDolphinExtensions |
|
31 |
allowExtendedBinarySelectors allowQualifiedNames |
|
32 |
allowFunctionCallSyntaxForBlockEvaluation |
|
1898 | 33 |
allowLocalVariableDeclarationWithInitializerExpression |
34 |
allowDomainVariables allowArrayIndexSyntaxExtension |
|
35 |
allowReservedWordsAsSelectors allowVariableReferences |
|
36 |
allowLazyValueExtension allowFixedPointLiterals |
|
37 |
allowExtendedSTXSyntax allowVisualAgeESSymbolLiterals |
|
38 |
allowExtensionsToPrivateClasses allowSqueakPrimitives |
|
39 |
allowVisualAgePrimitives allowSTVPrimitives allowSTVExtensions |
|
40 |
allowNationalCharactersInIdentifier allowHashAsBinarySelector |
|
1950 | 41 |
allowSTXEOLComments allowEmptyStatements |
42 |
allowVisualWorksMethodAnnotations |
|
43 |
allowPossibleSTCCompilationProblems arraysAreImmutable |
|
44 |
stringsAreImmutable implicitSelfSends stcKeepCIntermediate |
|
45 |
stcKeepOIntermediate stcKeepSTIntermediate stcModulePath |
|
46 |
stcCompilation stcCompilationIncludes stcCompilationDefines |
|
1898 | 47 |
stcCompilationOptions stcPath ccCompilationOptions ccPath |
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
48 |
linkArgs linkSharedArgs linkCommand libPath searchedLibraries |
2306 | 49 |
warnAboutPeriodInSymbol allowPeriodInSymbol allowCaretAsBinop' |
1898 | 50 |
classVariableNames:'WarnST80Directives WarnUnusedVars WarnUndeclared |
51 |
WarnAboutWrongVariableNames WarnAboutBadComments |
|
52 |
WarnAboutVariableNameConventions WarnSTXSpecials |
|
53 |
WarnOldStyleAssignment WarnUnderscoreInIdentifier |
|
54 |
WarnCommonMistakes WarnPossibleIncompatibilities |
|
55 |
WarnDollarInIdentifier WarnHiddenVariables |
|
56 |
WarnAboutNonLowercaseLocalVariableNames |
|
1950 | 57 |
WarnInconsistentReturnValues Warnings |
58 |
WarnAboutPossibleSTCCompilationProblems |
|
2121 | 59 |
WarnAboutReferenceToPrivateClass WarnAboutShortLocalVariableNames |
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
60 |
WarnAboutPossiblyUnimplementedSelectors WarnAboutPeriodInSymbol |
1950 | 61 |
AllowUnderscoreInIdentifier |
1898 | 62 |
AllowFunctionCallSyntaxForBlockEvaluation AllowLazyValueExtension |
63 |
AllowVariableReferences AllowReservedWordsAsSelectors |
|
64 |
AllowLocalVariableDeclarationWithInitializerExpression |
|
65 |
AllowArrayIndexSyntaxExtension AllowDomainVariables |
|
66 |
AllowDollarInIdentifier AllowSqueakExtensions AllowQualifiedNames |
|
67 |
AllowDolphinExtensions AllowOldStyleAssignment |
|
68 |
AllowExtendedBinarySelectors AllowExtendedSTXSyntax |
|
69 |
AllowFixedPointLiterals AllowLiteralNameSpaceSymbols |
|
70 |
AllowVisualAgeESSymbolLiterals AllowExtensionsToPrivateClasses |
|
71 |
AllowSqueakPrimitives AllowVisualAgePrimitives AllowSTVPrimitives |
|
72 |
AllowSTVExtensions AllowNationalCharactersInIdentifier |
|
1950 | 73 |
AllowHashAsBinarySelector AllowSTXEOLComments |
74 |
AllowPossibleSTCCompilationProblems AllowEmptyStatements |
|
75 |
AllowVisualWorksMethodAnnotations ArraysAreImmutable |
|
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
76 |
AllowPeriodInSymbol StringsAreImmutable ImplicitSelfSends |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
77 |
STCModulePath STCKeepCIntermediate STCKeepOIntermediate |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
78 |
STCKeepSTIntermediate STCCompilation STCCompilationIncludes |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
79 |
STCCompilationDefines STCCompilationOptions STCPath |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
80 |
CCCompilationOptions CCPath LinkArgs LinkSharedArgs LinkCommand |
2306 | 81 |
LibPath SearchedLibraries MakeCommand AllowCaretAsBinop' |
1898 | 82 |
poolDictionaries:'' |
83 |
category:'System-Compiler' |
|
1634 | 84 |
! |
85 |
||
86 |
!ParserFlags class methodsFor:'documentation'! |
|
87 |
||
88 |
copyright |
|
89 |
" |
|
90 |
COPYRIGHT (c) 1989 by Claus Gittinger |
|
91 |
COPYRIGHT (c) 2005 by eXept Software AG |
|
92 |
All Rights Reserved |
|
93 |
||
94 |
This software is furnished under a license and may be used |
|
95 |
only in accordance with the terms of that license and with the |
|
96 |
inclusion of the above copyright notice. This software may not |
|
97 |
be provided or otherwise made available to, or used by, any |
|
98 |
other person. No title to or ownership of the software is |
|
99 |
hereby transferred. |
|
100 |
" |
|
101 |
! |
|
102 |
||
103 |
documentation |
|
104 |
" |
|
105 |
compiler flags (used to be defined in Scanner and Parser) have been extracted for easier |
|
106 |
individual-method customization (using ST as scripting). |
|
1711 | 107 |
|
1712 | 108 |
howTo_fileInVSE: |
109 |
ParserFlags allowSTVExtensions:true. |
|
110 |
ParserFlags allowSTVPrimitives:true. |
|
111 |
ParserFlags allowSTXEOLComments:false. |
|
1711 | 112 |
" |
1634 | 113 |
! ! |
114 |
||
115 |
!ParserFlags class methodsFor:'instance creation'! |
|
116 |
||
117 |
new |
|
118 |
^ self basicNew initialize |
|
119 |
! ! |
|
120 |
||
121 |
!ParserFlags class methodsFor:'accessing-compilation control'! |
|
122 |
||
1668 | 123 |
allowExtensionsToPrivateClasses |
124 |
^ AllowExtensionsToPrivateClasses |
|
125 |
! |
|
126 |
||
127 |
allowExtensionsToPrivateClasses:aBoolean |
|
128 |
AllowExtensionsToPrivateClasses := aBoolean |
|
129 |
! |
|
130 |
||
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
131 |
allowPossibleSTCCompilationProblems |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
132 |
^ AllowPossibleSTCCompilationProblems |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
133 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
134 |
"Created: / 16-11-2006 / 14:31:36 / cg" |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
135 |
! |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
136 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
137 |
allowPossibleSTCCompilationProblems:aBoolean |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
138 |
AllowPossibleSTCCompilationProblems := aBoolean |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
139 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
140 |
"Created: / 16-11-2006 / 14:31:40 / cg" |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
141 |
! |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
142 |
|
1634 | 143 |
arraysAreImmutable |
144 |
"return true if arrays are immutable literals" |
|
145 |
||
146 |
^ ArraysAreImmutable |
|
147 |
! |
|
148 |
||
149 |
arraysAreImmutable:aBoolean |
|
150 |
"turn on/off immutable array literals - default is false for ST-80 compatibilty." |
|
151 |
||
152 |
ArraysAreImmutable := aBoolean. |
|
153 |
||
154 |
" |
|
155 |
can be added to your private.rc file: |
|
156 |
||
157 |
ParserFlags arraysAreImmutable:true |
|
158 |
ParserFlags arraysAreImmutable:false |
|
159 |
" |
|
160 |
! |
|
161 |
||
162 |
implicitSelfSends |
|
163 |
"return true if undefined variables with |
|
164 |
lowercase first character are to be turned |
|
165 |
into implicit self sends" |
|
166 |
||
167 |
^ ImplicitSelfSends |
|
168 |
! |
|
169 |
||
170 |
implicitSelfSends:aBoolean |
|
171 |
"turn on/off implicit self sends" |
|
172 |
||
173 |
ImplicitSelfSends := aBoolean |
|
174 |
||
175 |
" |
|
176 |
Compiler implicitSelfSends:true |
|
177 |
Compiler implicitSelfSends:false |
|
178 |
" |
|
179 |
! |
|
180 |
||
181 |
stringsAreImmutable |
|
182 |
"return true if strings are immutable literals" |
|
183 |
||
184 |
^ StringsAreImmutable |
|
185 |
||
186 |
"Created: / 3.8.1998 / 14:53:25 / cg" |
|
187 |
! |
|
188 |
||
189 |
stringsAreImmutable:aBoolean |
|
190 |
"turn on/off immutable string literals - default is false for ST-80 compatibilty." |
|
191 |
||
192 |
StringsAreImmutable := aBoolean. |
|
193 |
||
194 |
" |
|
195 |
can be added to your private.rc file: |
|
196 |
||
197 |
ParserFlags stringsAreImmutable:true |
|
198 |
ParserFlags stringsAreImmutable:false |
|
199 |
" |
|
200 |
||
201 |
"Created: / 3.8.1998 / 14:53:28 / cg" |
|
202 |
! ! |
|
203 |
||
1658 | 204 |
!ParserFlags class methodsFor:'accessing-stc compilation control'! |
205 |
||
206 |
ccCompilationOptions |
|
1668 | 207 |
^ CCCompilationOptions ? '' |
1658 | 208 |
! |
209 |
||
210 |
ccCompilationOptions:aString |
|
211 |
CCCompilationOptions := aString |
|
212 |
! |
|
213 |
||
214 |
ccPath |
|
215 |
^ CCPath |
|
216 |
! |
|
217 |
||
218 |
ccPath:aSymbol |
|
219 |
CCPath := aSymbol |
|
220 |
! |
|
221 |
||
222 |
libPath |
|
223 |
^ LibPath |
|
224 |
! |
|
225 |
||
226 |
libPath:aString |
|
227 |
LibPath := aString |
|
228 |
! |
|
229 |
||
230 |
linkArgs |
|
231 |
^ LinkArgs |
|
232 |
! |
|
233 |
||
234 |
linkArgs:aString |
|
235 |
LinkArgs := aString |
|
236 |
! |
|
237 |
||
238 |
linkCommand |
|
239 |
^ LinkCommand |
|
240 |
! |
|
241 |
||
242 |
linkCommand:aString |
|
243 |
LinkCommand := aString |
|
244 |
! |
|
245 |
||
1898 | 246 |
linkSharedArgs |
247 |
^ LinkSharedArgs |
|
248 |
! |
|
249 |
||
250 |
linkSharedArgs:aString |
|
251 |
LinkSharedArgs := aString |
|
252 |
! |
|
253 |
||
1814 | 254 |
makeCommand |
255 |
^ MakeCommand |
|
256 |
||
257 |
"Created: / 09-08-2006 / 18:45:04 / fm" |
|
258 |
! |
|
259 |
||
260 |
makeCommand:aString |
|
261 |
MakeCommand := aString |
|
262 |
||
263 |
"Created: / 09-08-2006 / 18:45:12 / fm" |
|
264 |
! |
|
265 |
||
1658 | 266 |
searchedLibraries |
267 |
^ SearchedLibraries |
|
268 |
! |
|
269 |
||
270 |
searchedLibraries:aString |
|
271 |
SearchedLibraries := aString |
|
272 |
! |
|
273 |
||
274 |
stcCompilation |
|
275 |
^ STCCompilation |
|
276 |
! |
|
277 |
||
278 |
stcCompilation:aSymbol |
|
279 |
STCCompilation := aSymbol |
|
280 |
! |
|
281 |
||
282 |
stcCompilationDefines |
|
283 |
^ STCCompilationDefines |
|
284 |
! |
|
285 |
||
286 |
stcCompilationDefines:aString |
|
287 |
STCCompilationDefines := aString |
|
288 |
! |
|
289 |
||
290 |
stcCompilationIncludes |
|
291 |
^ STCCompilationIncludes |
|
292 |
! |
|
293 |
||
294 |
stcCompilationIncludes:aString |
|
295 |
STCCompilationIncludes := aString |
|
296 |
! |
|
297 |
||
298 |
stcCompilationOptions |
|
299 |
^ STCCompilationOptions |
|
300 |
! |
|
301 |
||
302 |
stcCompilationOptions:aString |
|
303 |
STCCompilationOptions := aString |
|
304 |
! |
|
305 |
||
306 |
stcKeepCIntermediate |
|
307 |
^ STCKeepCIntermediate |
|
308 |
! |
|
309 |
||
310 |
stcKeepCIntermediate:something |
|
311 |
STCKeepCIntermediate := something. |
|
1940 | 312 |
|
313 |
" |
|
314 |
STCKeepCIntermediate := true. |
|
315 |
STCKeepCIntermediate := false. |
|
316 |
" |
|
317 |
||
318 |
"Modified: / 07-11-2006 / 10:58:42 / cg" |
|
1658 | 319 |
! |
320 |
||
321 |
stcKeepOIntermediate |
|
322 |
^ STCKeepOIntermediate |
|
323 |
! |
|
324 |
||
325 |
stcKeepOIntermediate:something |
|
326 |
STCKeepOIntermediate := something. |
|
327 |
! |
|
328 |
||
329 |
stcKeepSTIntermediate |
|
330 |
^ STCKeepSTIntermediate |
|
2142 | 331 |
|
332 |
" |
|
333 |
STCKeepSTIntermediate := true. |
|
334 |
STCKeepSTIntermediate := false. |
|
335 |
" |
|
1658 | 336 |
! |
337 |
||
338 |
stcKeepSTIntermediate:something |
|
339 |
STCKeepSTIntermediate := something. |
|
1940 | 340 |
|
341 |
" |
|
342 |
STCKeepSTIntermediate := true. |
|
343 |
STCKeepSTIntermediate := false. |
|
344 |
" |
|
345 |
||
346 |
"Modified: / 07-11-2006 / 10:58:54 / cg" |
|
1658 | 347 |
! |
348 |
||
349 |
stcModulePath |
|
350 |
^ STCModulePath |
|
351 |
! |
|
352 |
||
353 |
stcModulePath:something |
|
354 |
STCModulePath := something. |
|
355 |
! |
|
356 |
||
357 |
stcPath |
|
358 |
^ STCPath |
|
359 |
! |
|
360 |
||
361 |
stcPath:aSymbol |
|
362 |
STCPath := aSymbol |
|
363 |
! |
|
364 |
||
2011 | 365 |
useBorlandC |
366 |
"/ ^ true. |
|
367 |
^ OperatingSystem getCCDefine ='__BORLANDC__' |
|
368 |
||
369 |
"Created: / 15-03-2007 / 13:33:32 / cg" |
|
370 |
! |
|
371 |
||
372 |
useGnuC |
|
373 |
^ OperatingSystem getCCDefine = '__GNUC__' |
|
374 |
||
375 |
"Created: / 15-03-2007 / 13:34:49 / cg" |
|
376 |
! |
|
377 |
||
1658 | 378 |
withSTCCompilation:howSymbol do:aBlock |
379 |
|prev| |
|
380 |
||
381 |
prev := self stcCompilation. |
|
382 |
self stcCompilation:howSymbol. |
|
383 |
aBlock ensure:[ self stcCompilation:prev ] |
|
384 |
! ! |
|
385 |
||
1634 | 386 |
!ParserFlags class methodsFor:'accessing-syntax-control'! |
387 |
||
388 |
allowArrayIndexSyntaxExtension |
|
389 |
"experimental" |
|
390 |
||
391 |
^ AllowArrayIndexSyntaxExtension ? false |
|
392 |
! |
|
393 |
||
394 |
allowArrayIndexSyntaxExtension:aBoolean |
|
395 |
"experimental" |
|
396 |
||
397 |
AllowArrayIndexSyntaxExtension := aBoolean. |
|
398 |
||
399 |
" |
|
400 |
self allowArrayIndexSyntaxExtension:true |
|
401 |
self allowArrayIndexSyntaxExtension:false |
|
402 |
" |
|
403 |
! |
|
404 |
||
405 |
allowDollarInIdentifier |
|
406 |
"return true, if $-characters are allowed in identifiers. |
|
407 |
Notice, that dollars are NEVER allowed as the first character in an identifier." |
|
408 |
||
409 |
^ AllowDollarInIdentifier |
|
410 |
||
411 |
"Created: 7.9.1997 / 01:32:18 / cg" |
|
412 |
"Modified: 7.9.1997 / 01:39:44 / cg" |
|
413 |
! |
|
414 |
||
415 |
allowDollarInIdentifier:aBoolean |
|
416 |
"this allows turning on/off $-characters in identifiers. |
|
417 |
Notice, that dollars are NEVER allowed as the first character in an identifier. |
|
418 |
If turned off (the default), dollars are not allowed in identifiers, |
|
419 |
but instead are scanned as character-constant prefix. |
|
420 |
If turned on, dollars are in identifiers are allowed, while extra |
|
421 |
dollars are still scanned as constant character prefix. |
|
422 |
If you have to fileIn old VW-Vsn2.x classes, turn this off |
|
423 |
before filing them in; i.e.: |
|
424 |
Compiler allowDollarInIdentifiers:false" |
|
425 |
||
426 |
AllowDollarInIdentifier := aBoolean. |
|
427 |
||
428 |
"Created: 7.9.1997 / 01:34:49 / cg" |
|
429 |
"Modified: 7.9.1997 / 01:39:30 / cg" |
|
430 |
! |
|
431 |
||
432 |
allowDolphinExtensions |
|
433 |
"return true, if ##(..) computed literals are allowed" |
|
434 |
||
435 |
^ AllowDolphinExtensions |
|
436 |
! |
|
437 |
||
438 |
allowDolphinExtensions:aBoolean |
|
439 |
"this allows turning on/off support for computed arrays ##(..) as in dolphin. |
|
440 |
If you want to fileIn Dolphin classes, enable this with: |
|
441 |
Compiler allowDolphinComputedArrays:true" |
|
442 |
||
443 |
AllowDolphinExtensions := aBoolean. |
|
444 |
||
445 |
" |
|
446 |
self allowDolphinExtensions:true |
|
447 |
self allowDolphinExtensions:false |
|
448 |
" |
|
449 |
! |
|
450 |
||
1950 | 451 |
allowEmptyStatements |
452 |
"return true, if empty statements are allowed (two .'s in a row). |
|
453 |
Notice, that stc cannot (yet) handle those." |
|
454 |
||
455 |
^ AllowEmptyStatements |
|
456 |
||
457 |
"Created: / 20-11-2006 / 14:29:02 / cg" |
|
458 |
! |
|
459 |
||
460 |
allowEmptyStatements:aBoolean |
|
461 |
"turn on/off, if empty statements are allowed (two .'s in a row). |
|
462 |
Notice, that stc cannot (yet) handle those." |
|
463 |
||
464 |
AllowEmptyStatements := aBoolean |
|
465 |
||
466 |
"Created: / 20-11-2006 / 14:29:15 / cg" |
|
467 |
! |
|
468 |
||
2145 | 469 |
allowExtendedBinarySelectors |
470 |
"experimental extended selectors extensions" |
|
471 |
||
472 |
^ AllowExtendedBinarySelectors |
|
2218
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
473 |
|
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
474 |
" |
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
475 |
ParserFlags allowExtendedBinarySelectors |
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
476 |
ParserFlags allowExtendedBinarySelectors:false |
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
477 |
ParserFlags allowExtendedBinarySelectors:true |
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
478 |
" |
2145 | 479 |
! |
480 |
||
481 |
allowExtendedBinarySelectors:aBoolean |
|
482 |
"experimental syntay extensions" |
|
483 |
||
484 |
AllowExtendedBinarySelectors := aBoolean |
|
485 |
! |
|
486 |
||
1682 | 487 |
allowExtendedSTXSyntax |
488 |
"experimental syntay extensions" |
|
489 |
||
490 |
^ AllowExtendedSTXSyntax |
|
491 |
! |
|
492 |
||
493 |
allowExtendedSTXSyntax:aBoolean |
|
494 |
"experimental syntay extensions" |
|
495 |
||
496 |
AllowExtendedSTXSyntax := aBoolean |
|
497 |
||
498 |
" |
|
499 |
self allowExtendedSTXSyntax:true |
|
500 |
'a\tb' inspect. |
|
501 |
'a\u1616b' inspect. |
|
502 |
self allowExtendedSTXSyntax:false |
|
503 |
" |
|
504 |
! |
|
505 |
||
1677 | 506 |
allowFixedPointLiterals |
507 |
"return true, if nnnsn (FixedPoint) literals are allowed" |
|
508 |
||
509 |
^ AllowFixedPointLiterals |
|
510 |
! |
|
511 |
||
512 |
allowFixedPointLiterals:aBoolean |
|
513 |
"enable/disable, if nnnsn (FixedPoint) literals are allowed" |
|
514 |
||
515 |
AllowFixedPointLiterals := aBoolean |
|
516 |
! |
|
517 |
||
1634 | 518 |
allowFunctionCallSyntaxForBlockEvaluation |
519 |
"experimental" |
|
520 |
||
521 |
^ AllowFunctionCallSyntaxForBlockEvaluation |
|
1721 | 522 |
|
523 |
" |
|
524 |
AllowFunctionCallSyntaxForBlockEvaluation := true |
|
525 |
" |
|
1634 | 526 |
! |
527 |
||
528 |
allowFunctionCallSyntaxForBlockEvaluation:aBoolean |
|
529 |
"experimental" |
|
530 |
||
531 |
AllowFunctionCallSyntaxForBlockEvaluation := aBoolean. |
|
532 |
! |
|
533 |
||
1706
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
534 |
allowHashAsBinarySelector |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
535 |
^ AllowHashAsBinarySelector |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
536 |
! |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
537 |
|
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
538 |
allowHashAsBinarySelector:aBoolean |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
539 |
AllowHashAsBinarySelector := aBoolean |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
540 |
|
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
541 |
" |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
542 |
self allowHashAsBinarySelector:true |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
543 |
self allowHashAsBinarySelector:false |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
544 |
" |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
545 |
! |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
546 |
|
1634 | 547 |
allowLiteralNameSpaceSymbols |
548 |
"return true, if literal nameSpace symbols are allowed (#foo::bar) are allowed" |
|
549 |
||
550 |
^ AllowLiteralNameSpaceSymbols |
|
551 |
! |
|
552 |
||
553 |
allowLiteralNameSpaceSymbols:aBoolean |
|
554 |
"controls, if literal nameSpace symbols are allowed (#foo::bar) are allowed" |
|
555 |
||
556 |
AllowLiteralNameSpaceSymbols := aBoolean |
|
557 |
! |
|
558 |
||
559 |
allowLocalVariableDeclarationWithInitializerExpression |
|
560 |
"experimental" |
|
561 |
||
562 |
^ AllowLocalVariableDeclarationWithInitializerExpression |
|
563 |
! |
|
564 |
||
565 |
allowLocalVariableDeclarationWithInitializerExpression:aBoolean |
|
566 |
"experimental" |
|
567 |
||
568 |
AllowLocalVariableDeclarationWithInitializerExpression := aBoolean. |
|
569 |
! |
|
570 |
||
1706
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
571 |
allowNationalCharactersInIdentifier |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
572 |
"return true, if national characters (diaresis etc.) are allowed in identifiers" |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
573 |
|
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
574 |
^ AllowNationalCharactersInIdentifier |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
575 |
! |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
576 |
|
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
577 |
allowNationalCharactersInIdentifier:aBoolean |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
578 |
"this allows turning on/off recognition of national characters (diaresis etc.) in identifiers. |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
579 |
Use this ONLY to file in some non-ANSI ST/V code" |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
580 |
|
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
581 |
AllowNationalCharactersInIdentifier := aBoolean |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
582 |
|
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
583 |
" |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
584 |
ParserFlags allowNationalCharactersInIdentifier:true |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
585 |
" |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
586 |
! |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
587 |
|
1634 | 588 |
allowOldStyleAssignment |
589 |
"return true, if underscore-assignment (pre ST-80v4 syntax) are to be allowed" |
|
590 |
||
591 |
^ AllowOldStyleAssignment |
|
592 |
! |
|
593 |
||
594 |
allowOldStyleAssignment:aBoolean |
|
595 |
"this allows turning on/off recognition of underscore-assignment (pre ST-80v4 syntax). |
|
596 |
You must turn this off, if code with variables named '_' is to be filedIn" |
|
597 |
||
598 |
AllowOldStyleAssignment := aBoolean |
|
599 |
! |
|
600 |
||
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
601 |
allowPeriodInSymbol |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
602 |
"return true, if periods are allowed in a symbol literal #foo.bar. |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
603 |
Needed to parse some old ST80/Squeak code" |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
604 |
|
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
605 |
^ AllowPeriodInSymbol |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
606 |
! |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
607 |
|
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
608 |
allowPeriodInSymbol:aBoolean |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
609 |
"control, if periods are allowed in a symbol literal #foo.bar. |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
610 |
Needed to parse some old ST80/Squeak code" |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
611 |
|
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
612 |
AllowPeriodInSymbol := aBoolean |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
613 |
|
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
614 |
" |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
615 |
self allowPeriodInSymbol:true. |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
616 |
self assert:( Parser parseExpression:' #foo.bar.baz. ' ) value == #'foo.bar.baz'. |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
617 |
|
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
618 |
self allowPeriodInSymbol:false. |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
619 |
self assert:( Parser parseExpression:' #foo.bar.baz. ' ) value == #'foo'. |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
620 |
" |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
621 |
! |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
622 |
|
1634 | 623 |
allowQualifiedNames |
624 |
"return true, if #{..} qualified names are allowed" |
|
625 |
||
626 |
^ AllowQualifiedNames |
|
627 |
! |
|
628 |
||
629 |
allowQualifiedNames:aBoolean |
|
630 |
"this allows turning on/off support for qualifiedNames #{ .., } as in vw3. |
|
631 |
If you want to fileIn vw3 or later classes, enable this with: |
|
632 |
Compiler allowQualifiedNames:true |
|
633 |
Notice, that qualified names are not really supported semantically |
|
634 |
(they are parsed, but treated like regular globals) |
|
635 |
" |
|
636 |
||
637 |
AllowQualifiedNames := aBoolean. |
|
638 |
||
639 |
" |
|
640 |
self allowQualifiedNames:true |
|
641 |
self allowQualifiedNames:false |
|
642 |
" |
|
643 |
! |
|
644 |
||
645 |
allowReservedWordsAsSelectors |
|
646 |
"return true, if self, super, thisContext, nil, true and false are to be allowed |
|
647 |
as unary message selectors." |
|
648 |
||
649 |
^ AllowReservedWordsAsSelectors ? false |
|
650 |
! |
|
651 |
||
652 |
allowReservedWordsAsSelectors:aBoolean |
|
653 |
"enable/disable, if self, super, thisContext, nil, true and false are to be allowed |
|
654 |
as unary message selectors." |
|
655 |
||
656 |
AllowReservedWordsAsSelectors := aBoolean. |
|
657 |
||
658 |
" |
|
659 |
self allowReservedWordsAsSelectors:true |
|
660 |
self allowReservedWordsAsSelectors:false |
|
661 |
" |
|
662 |
! |
|
663 |
||
1702 | 664 |
allowSTVExtensions |
665 |
"return true, if support for ST/V syntax extensions is enabled." |
|
666 |
||
667 |
^ AllowSTVExtensions |
|
668 |
! |
|
669 |
||
670 |
allowSTVExtensions:aBoolean |
|
671 |
"this allows turning on/off support for ST/V extensions: |
|
672 |
If you want to fileIn ST/V classes, enable this with: |
|
673 |
Compiler allowSTVComputedArrays:true" |
|
674 |
||
675 |
AllowSTVExtensions := aBoolean. |
|
676 |
||
677 |
" |
|
1704 | 678 |
ParserFlags allowSTVExtensions:true |
679 |
ParserFlags allowSTVExtensions:false |
|
1702 | 680 |
" |
681 |
! |
|
682 |
||
1700 | 683 |
allowSTVPrimitives |
684 |
"return true, if support for ST/V primitives is enabled." |
|
685 |
||
686 |
^ AllowSTVPrimitives |
|
687 |
! |
|
688 |
||
689 |
allowSTVPrimitives:aBoolean |
|
690 |
"this allows turning on/off support for ST/V primitives" |
|
691 |
||
692 |
AllowSTVPrimitives := aBoolean |
|
1704 | 693 |
|
694 |
" |
|
695 |
ParserFlags allowSTVPrimitives:true |
|
696 |
" |
|
1700 | 697 |
! |
698 |
||
1708
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
699 |
allowSTXEOLComments |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
700 |
^ AllowSTXEOLComments |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
701 |
! |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
702 |
|
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
703 |
allowSTXEOLComments:aBoolean |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
704 |
AllowSTXEOLComments := aBoolean. |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
705 |
|
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
706 |
" |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
707 |
self allowSTXEOLComments:true |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
708 |
self allowSTXEOLComments:false |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
709 |
" |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
710 |
! |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
711 |
|
1634 | 712 |
allowSqueakExtensions |
713 |
"return true, if support for squeak extensions |
|
714 |
computed arrays { .., } |
|
715 |
c/java style arguments in message sends rec foo(arg1, ... argN) |
|
716 |
is enabled." |
|
717 |
||
718 |
^ AllowSqueakExtensions |
|
719 |
! |
|
720 |
||
721 |
allowSqueakExtensions:aBoolean |
|
722 |
"this allows turning on/off support for squeak extensions: |
|
723 |
computed arrays { .., } |
|
724 |
c/java style arguments in message sends rec foo(arg1, ... argN) |
|
725 |
||
726 |
If you want to fileIn Squeak classes, enable this with: |
|
727 |
Compiler allowSqueakComputedArrays:true" |
|
728 |
||
729 |
AllowSqueakExtensions := aBoolean. |
|
730 |
||
731 |
" |
|
732 |
self allowSqueakExtensions:true |
|
733 |
self allowSqueakExtensions:false |
|
734 |
" |
|
735 |
! |
|
736 |
||
1689 | 737 |
allowSqueakPrimitives |
738 |
"return true, if support for squeak primitives is enabled." |
|
739 |
||
740 |
^ AllowSqueakPrimitives |
|
741 |
! |
|
742 |
||
743 |
allowSqueakPrimitives:aBoolean |
|
744 |
"this allows turning on/off support for squeak primitives" |
|
745 |
||
746 |
AllowSqueakPrimitives := aBoolean |
|
747 |
! |
|
748 |
||
1634 | 749 |
allowUnderscoreInIdentifier |
750 |
"return true, if underscores are allowed in identifiers" |
|
751 |
||
752 |
^ AllowUnderscoreInIdentifier |
|
753 |
! |
|
754 |
||
755 |
allowUnderscoreInIdentifier:aBoolean |
|
756 |
"this allows turning on/off underscores in identifiers. |
|
757 |
If turned off (the default), underscores are not allowed in identifiers, |
|
758 |
but instead scanned as assignment character (old ST/80 syntax). |
|
759 |
If turned on, underscores are in identifiers are allowed, while extra |
|
760 |
underscores are still scanned as assignment. |
|
761 |
If you have to fileIn old VW-Vsn2.x classes, |
|
762 |
turn them off with: |
|
763 |
Compiler allowUnderscoreInIdentifiers:false" |
|
764 |
||
765 |
AllowUnderscoreInIdentifier := aBoolean. |
|
766 |
||
767 |
"Modified: 7.9.1997 / 01:35:19 / cg" |
|
1655 | 768 |
! |
769 |
||
770 |
allowVisualAgeESSymbolLiterals |
|
771 |
"return true, if ##symbols are allowed (treated like symbols)" |
|
772 |
||
773 |
^ AllowVisualAgeESSymbolLiterals |
|
774 |
! |
|
775 |
||
776 |
allowVisualAgeESSymbolLiterals:aBoolean |
|
777 |
"if on, visualAge's ##symbols are allowed (treated like symbols)" |
|
778 |
||
779 |
AllowVisualAgeESSymbolLiterals := aBoolean. |
|
1689 | 780 |
! |
781 |
||
782 |
allowVisualAgePrimitives |
|
783 |
"return true, if support for V'Age primitives is enabled." |
|
784 |
||
785 |
^ AllowVisualAgePrimitives |
|
786 |
! |
|
787 |
||
788 |
allowVisualAgePrimitives:aBoolean |
|
789 |
"this allows turning on/off support for V'Age primitives" |
|
790 |
||
791 |
AllowVisualAgePrimitives := aBoolean |
|
1773 | 792 |
! |
793 |
||
794 |
allowVisualWorksMethodAnnotations |
|
795 |
"return true, if support for V'Works extended primitive syntax for method annotations." |
|
796 |
||
797 |
^ AllowVisualWorksMethodAnnotations |
|
798 |
||
799 |
"Created: / 07-07-2006 / 15:49:32 / cg" |
|
800 |
! |
|
801 |
||
802 |
allowVisualWorksMethodAnnotations:aBoolean |
|
803 |
"turn on/off support for V'Works extended primitive syntax for method annotations." |
|
804 |
||
805 |
AllowVisualWorksMethodAnnotations := aBoolean |
|
806 |
||
807 |
"Created: / 07-07-2006 / 15:49:27 / cg" |
|
1634 | 808 |
! ! |
809 |
||
810 |
!ParserFlags class methodsFor:'accessing-warning-control'! |
|
811 |
||
1652 | 812 |
warnAboutBadComments |
813 |
"controls generation of warning messages about empty comments" |
|
814 |
||
815 |
^ WarnAboutBadComments |
|
816 |
! |
|
817 |
||
818 |
warnAboutBadComments:aBoolean |
|
819 |
"controls generation of warning messages about empty comments" |
|
820 |
||
821 |
WarnAboutBadComments := aBoolean |
|
822 |
! |
|
823 |
||
1811 | 824 |
warnAboutNonLowercaseLocalVariableNames |
1740 | 825 |
"controls generation of warning messages about wrong variable names" |
826 |
||
1811 | 827 |
^ WarnAboutNonLowercaseLocalVariableNames |
1740 | 828 |
! |
829 |
||
1811 | 830 |
warnAboutNonLowercaseLocalVariableNames:aBoolean |
1740 | 831 |
"controls generation of warning messages about wrong variable names" |
832 |
||
1811 | 833 |
WarnAboutNonLowercaseLocalVariableNames := aBoolean |
1740 | 834 |
! |
835 |
||
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
836 |
warnAboutPeriodInSymbol |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
837 |
^ WarnAboutPeriodInSymbol |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
838 |
! |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
839 |
|
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
840 |
warnAboutPeriodInSymbol:aBoolean |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
841 |
WarnAboutPeriodInSymbol := aBoolean |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
842 |
! |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
843 |
|
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
844 |
warnAboutPossibleSTCCompilationProblems |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
845 |
^ WarnAboutPossibleSTCCompilationProblems |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
846 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
847 |
"Created: / 16-11-2006 / 14:31:52 / cg" |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
848 |
! |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
849 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
850 |
warnAboutPossibleSTCCompilationProblems:aBoolean |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
851 |
WarnAboutPossibleSTCCompilationProblems := aBoolean |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
852 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
853 |
"Created: / 16-11-2006 / 14:31:57 / cg" |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
854 |
! |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
855 |
|
2121 | 856 |
warnAboutPossiblyUnimplementedSelectors |
857 |
^ WarnAboutPossiblyUnimplementedSelectors |
|
858 |
! |
|
859 |
||
860 |
warnAboutPossiblyUnimplementedSelectors:aBoolean |
|
861 |
WarnAboutPossiblyUnimplementedSelectors := aBoolean |
|
862 |
! |
|
863 |
||
2073
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
864 |
warnAboutReferenceToPrivateClass |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
865 |
"controls generation of warning messages when a private class is referenced" |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
866 |
|
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
867 |
^ WarnAboutReferenceToPrivateClass |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
868 |
! |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
869 |
|
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
870 |
warnAboutReferenceToPrivateClass:aBoolean |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
871 |
"controls generation of warning messages when a private class is referenced" |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
872 |
|
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
873 |
WarnAboutReferenceToPrivateClass := aBoolean |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
874 |
! |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
875 |
|
2081
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
876 |
warnAboutShortLocalVariableNames |
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
877 |
"controls generation of warning messages about short variable names" |
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
878 |
|
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
879 |
^ WarnAboutShortLocalVariableNames |
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
880 |
! |
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
881 |
|
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
882 |
warnAboutShortLocalVariableNames:aBoolean |
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
883 |
"controls generation of warning messages about short variable names" |
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
884 |
|
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
885 |
WarnAboutShortLocalVariableNames := aBoolean |
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
886 |
! |
a8b56888f91c
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2079
diff
changeset
|
887 |
|
1634 | 888 |
warnAboutVariableNameConventions |
889 |
"controls generation of warning messages about wrong variable names" |
|
890 |
||
891 |
^ WarnAboutVariableNameConventions |
|
892 |
! |
|
893 |
||
894 |
warnAboutVariableNameConventions:aBoolean |
|
895 |
"controls generation of warning messages about wrong variable names" |
|
896 |
||
897 |
WarnAboutVariableNameConventions := aBoolean |
|
898 |
! |
|
899 |
||
900 |
warnAboutWrongVariableNames |
|
901 |
"controls generation of warning messages about wrong variable names" |
|
902 |
||
903 |
^ WarnAboutWrongVariableNames |
|
904 |
! |
|
905 |
||
906 |
warnAboutWrongVariableNames:aBoolean |
|
907 |
"controls generation of warning messages about wrong variable names" |
|
908 |
||
909 |
WarnAboutWrongVariableNames := aBoolean |
|
910 |
! |
|
911 |
||
912 |
warnCommonMistakes |
|
913 |
"return true, if common beginners mistakes are to be warned about" |
|
914 |
||
1754 | 915 |
^ WarnCommonMistakes |
1634 | 916 |
! |
917 |
||
918 |
warnCommonMistakes:aBoolean |
|
919 |
"this allows turning on/off warnings about common beginners mistakes. |
|
920 |
Those are not really errors in the strict sense, but often lead to |
|
921 |
run time errors later. |
|
922 |
Examples are: expr or:expr2, where expr2 is not a block. |
|
923 |
If you get bored by those warnings, turn them off by adding |
|
924 |
a line as: |
|
1902 | 925 |
ParserFlags warnCommonMistakes:false |
1634 | 926 |
in your 'private.rc' file" |
927 |
||
928 |
WarnCommonMistakes := aBoolean |
|
1902 | 929 |
|
930 |
"Modified: / 05-09-2006 / 11:46:26 / cg" |
|
1634 | 931 |
! |
932 |
||
933 |
warnDollarInIdentifier |
|
934 |
"return true, if $-characters in identifiers are to be warned about" |
|
935 |
||
936 |
^ Warnings and:[WarnDollarInIdentifier] |
|
937 |
||
938 |
"Created: 7.9.1997 / 01:36:17 / cg" |
|
939 |
! |
|
940 |
||
941 |
warnDollarInIdentifier:aBoolean |
|
942 |
"this allows turning on/off warnings about $-characters in identifiers. |
|
943 |
You may find those warnings useful, to make certain that your code |
|
944 |
is portable to other smalltalk versions, which do not allow this |
|
945 |
(i.e. VW releases 2.x and maybe others). |
|
946 |
Notice, that dollars are NEVER allowed as the first character in an identifier. |
|
947 |
If you get bored by those warnings, turn them off by adding |
|
948 |
a line as: |
|
1902 | 949 |
ParserFlags warnDollarInIdentifier:false |
1634 | 950 |
in your 'private.rc' file" |
951 |
||
952 |
WarnDollarInIdentifier := aBoolean |
|
953 |
||
1902 | 954 |
"Created: / 07-09-1997 / 01:37:42 / cg" |
955 |
"Modified: / 05-09-2006 / 11:46:23 / cg" |
|
1634 | 956 |
! |
957 |
||
1682 | 958 |
warnHiddenVariables |
959 |
"controls generation of warning messages about hiding variables by locals" |
|
960 |
||
961 |
^ WarnHiddenVariables |
|
962 |
! |
|
963 |
||
964 |
warnHiddenVariables:aBoolean |
|
965 |
"controls generation of warning messages about hiding variables by locals" |
|
966 |
||
967 |
WarnHiddenVariables := aBoolean |
|
968 |
! |
|
969 |
||
970 |
warnInconsistentReturnValues |
|
971 |
"return true, if compiler should warn about inconsitent (boolean / non-boolean) |
|
972 |
return values" |
|
973 |
||
974 |
^ WarnInconsistentReturnValues |
|
975 |
! |
|
976 |
||
977 |
warnInconsistentReturnValues:aBoolean |
|
978 |
"constrols if the compiler should warn about inconsitent (boolean / non-boolean) |
|
979 |
return values" |
|
980 |
||
981 |
WarnInconsistentReturnValues := aBoolean |
|
982 |
! |
|
983 |
||
1634 | 984 |
warnOldStyleAssignment |
985 |
"return true, if underscore-assignment (pre ST-80v4 syntax) are to be warned about" |
|
986 |
||
987 |
^ Warnings and:[WarnOldStyleAssignment] |
|
988 |
! |
|
989 |
||
990 |
warnOldStyleAssignment:aBoolean |
|
991 |
"this allows turning on/off warnings about underscore-assignment (pre ST-80v4 syntax). |
|
992 |
If you get bored by those warnings, turn them off by adding |
|
993 |
a line as: |
|
1902 | 994 |
ParserFlags warnOldStyleAssignment:false |
1634 | 995 |
in your 'private.rc' file" |
996 |
||
997 |
WarnOldStyleAssignment := aBoolean |
|
1902 | 998 |
|
999 |
"Modified: / 05-09-2006 / 11:46:17 / cg" |
|
1634 | 1000 |
! |
1001 |
||
1002 |
warnPossibleIncompatibilities |
|
1003 |
"return true, if possible incompatibilities (with other ST systems) |
|
1004 |
are to be warned about" |
|
1005 |
||
1006 |
^ Warnings and:[WarnPossibleIncompatibilities] |
|
1007 |
||
1008 |
"Modified: 23.5.1997 / 12:02:02 / cg" |
|
1009 |
! |
|
1010 |
||
1011 |
warnPossibleIncompatibilities:aBoolean |
|
1012 |
"this turns warnings about possible incompatibilities (with other ST systems) |
|
1013 |
on or off. |
|
1014 |
If you get bored by those warnings, turn them off by adding |
|
1015 |
a line as: |
|
1902 | 1016 |
ParserFlags warnPossibleIncompatibilities:false |
1634 | 1017 |
in your 'private.rc' file." |
1018 |
||
1019 |
WarnPossibleIncompatibilities := aBoolean |
|
1020 |
||
1902 | 1021 |
"Created: / 23-05-1997 / 12:02:45 / cg" |
1022 |
"Modified: / 05-09-2006 / 11:46:14 / cg" |
|
1634 | 1023 |
! |
1024 |
||
1025 |
warnSTXSpecials |
|
1026 |
"return true, if ST/X specials are to be warned about" |
|
1027 |
||
1028 |
^ Warnings and:[WarnSTXSpecials] |
|
1029 |
! |
|
1030 |
||
1031 |
warnSTXSpecials:aBoolean |
|
1032 |
"this allows turning on/off warnings about stx specials. |
|
1033 |
If you get bored by those warnings, turn them off by adding |
|
1034 |
a line as: |
|
1902 | 1035 |
ParserFlags warnSTXSpecials:false |
1634 | 1036 |
in your 'private.rc' file" |
1037 |
||
1038 |
WarnSTXSpecials := aBoolean |
|
1902 | 1039 |
|
1040 |
"Modified: / 05-09-2006 / 11:46:11 / cg" |
|
1634 | 1041 |
! |
1042 |
||
1043 |
warnUnderscoreInIdentifier |
|
1044 |
"return true, if underscores in identifiers are to be warned about" |
|
1045 |
||
1046 |
^ Warnings and:[WarnUnderscoreInIdentifier] |
|
1047 |
! |
|
1048 |
||
1049 |
warnUnderscoreInIdentifier:aBoolean |
|
1050 |
"this allows turning on/off warnings about underscores in identifiers. |
|
1051 |
You may find those warnings useful, to make certain that your code |
|
1052 |
is portable to other smalltalk versions, which do not allow this |
|
1053 |
(i.e. VW releases 2.x). |
|
1054 |
If you get bored by those warnings, turn them off by adding |
|
1055 |
a line as: |
|
1902 | 1056 |
ParserFlags warnUnderscoreInIdentifier:false |
1634 | 1057 |
in your 'private.rc' file" |
1058 |
||
1059 |
WarnUnderscoreInIdentifier := aBoolean |
|
1060 |
||
1902 | 1061 |
"Modified: / 05-09-2006 / 11:46:08 / cg" |
1634 | 1062 |
! |
1063 |
||
1064 |
warnUnusedVars |
|
1065 |
"controls generation of warning messages about unued method variables" |
|
1066 |
||
1067 |
^ WarnUnusedVars |
|
1068 |
! |
|
1069 |
||
1070 |
warnUnusedVars:aBoolean |
|
1071 |
"controls generation of warning messages about unued method variables" |
|
1072 |
||
1073 |
WarnUnusedVars := aBoolean |
|
1074 |
! |
|
1075 |
||
1076 |
warnings |
|
1077 |
"return true, if any warnings are to be shown" |
|
1078 |
||
1079 |
^ Warnings |
|
1080 |
! |
|
1081 |
||
1082 |
warnings:aBoolean |
|
1083 |
"this allows turning on/off all warnings; the default is on. |
|
1084 |
You can turn off warnings in your 'private.rc' file with |
|
1902 | 1085 |
ParserFlags warnings:false |
1634 | 1086 |
" |
1087 |
||
1088 |
Warnings := aBoolean |
|
1089 |
||
1902 | 1090 |
" |
1091 |
ParserFlags warnings |
|
1092 |
ParserFlags warnings:true |
|
1093 |
ParserFlags warnings:false |
|
1094 |
" |
|
1095 |
||
1096 |
"Modified: / 05-09-2006 / 11:46:47 / cg" |
|
1634 | 1097 |
! ! |
1098 |
||
1099 |
!ParserFlags class methodsFor:'class initialization'! |
|
1100 |
||
1101 |
initialize |
|
1102 |
Warnings := true. |
|
1103 |
WarnUndeclared := true. |
|
1104 |
WarnUnusedVars := true. |
|
1105 |
WarnSTXSpecials := false. |
|
1106 |
WarnST80Directives := false. |
|
1107 |
WarnAboutWrongVariableNames := true. |
|
1108 |
WarnAboutVariableNameConventions := true. |
|
1652 | 1109 |
WarnAboutBadComments := true. |
1634 | 1110 |
WarnUnderscoreInIdentifier := false. |
1111 |
WarnDollarInIdentifier := true. |
|
1112 |
WarnOldStyleAssignment := true. |
|
1113 |
WarnCommonMistakes := true. |
|
1114 |
WarnPossibleIncompatibilities := false. |
|
1638 | 1115 |
WarnHiddenVariables := true. |
1682 | 1116 |
WarnInconsistentReturnValues := true. |
1811 | 1117 |
WarnAboutNonLowercaseLocalVariableNames := true. |
2083
9e9ee3362d7d
Switch off short variable name warnings
Stefan Vogel <sv@exept.de>
parents:
2081
diff
changeset
|
1118 |
WarnAboutShortLocalVariableNames := false. |
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1119 |
WarnAboutPossibleSTCCompilationProblems := true. |
2073
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1120 |
WarnAboutReferenceToPrivateClass := true. |
2121 | 1121 |
WarnAboutPossiblyUnimplementedSelectors := true. |
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1122 |
WarnAboutPeriodInSymbol := true. |
1634 | 1123 |
|
1124 |
AllowReservedWordsAsSelectors := false. |
|
1125 |
AllowUnderscoreInIdentifier := true. "/ underscores in identifiers |
|
1126 |
AllowDollarInIdentifier := false. "/ st80-vms dollars in identifiers |
|
1127 |
AllowOldStyleAssignment := true. "/ st80 underscore as assignment |
|
1128 |
AllowDolphinExtensions := false. "/ dolphin computed literal |
|
1129 |
AllowQualifiedNames := false. "/ vw3 qualified names |
|
1130 |
AllowExtendedBinarySelectors := false. "/ vw5.4 extended binary selectors (plus/minus, center-dot etc.) |
|
2306 | 1131 |
AllowCaretAsBinop := false. "/ too dangerous |
1634 | 1132 |
AllowLiteralNameSpaceSymbols := true. "/ st/x literal nameSpace-symbols (#foo::bar) |
1133 |
AllowArrayIndexSyntaxExtension := false. |
|
1134 |
AllowFunctionCallSyntaxForBlockEvaluation := false. |
|
1135 |
AllowLocalVariableDeclarationWithInitializerExpression := false. |
|
1136 |
AllowDomainVariables := false. |
|
1137 |
AllowArrayIndexSyntaxExtension := false. |
|
1138 |
AllowReservedWordsAsSelectors := true. |
|
1139 |
AllowVariableReferences := false. |
|
1140 |
AllowLazyValueExtension := false. |
|
1141 |
AllowFixedPointLiterals := false. |
|
1142 |
AllowExtendedSTXSyntax := false. |
|
1655 | 1143 |
AllowVisualAgeESSymbolLiterals := false. |
1668 | 1144 |
AllowExtensionsToPrivateClasses := true. |
1689 | 1145 |
AllowVisualAgePrimitives := false. |
1702 | 1146 |
AllowSqueakExtensions := false. "/ squeak computed array |
1689 | 1147 |
AllowSqueakPrimitives := false. |
1702 | 1148 |
AllowSTVPrimitives := false. "/ number-sign syntax |
1149 |
AllowSTVExtensions := false. |
|
1706
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1150 |
AllowNationalCharactersInIdentifier := false. |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1151 |
AllowHashAsBinarySelector := true. |
1708
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1152 |
AllowSTXEOLComments := true. |
1773 | 1153 |
AllowVisualWorksMethodAnnotations := false. |
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1154 |
AllowPossibleSTCCompilationProblems := true. |
1950 | 1155 |
AllowEmptyStatements := false. |
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1156 |
AllowPeriodInSymbol := false. |
1634 | 1157 |
|
1158 |
ArraysAreImmutable := false. "/ no longer care for ST-80 compatibility |
|
1159 |
StringsAreImmutable := false. "/ no longer care for ST-80 compatibility |
|
1160 |
ImplicitSelfSends := false. |
|
1161 |
||
1658 | 1162 |
STCKeepCIntermediate := false. |
1163 |
STCKeepOIntermediate := false. |
|
1164 |
STCKeepSTIntermediate := false. |
|
1165 |
STCModulePath := './modules'. |
|
1166 |
STCCompilation := #default. |
|
1167 |
||
1168 |
OperatingSystem isMSWINDOWSlike ifTrue:[ |
|
1668 | 1169 |
'C:\Borland\bcc55' asFilename exists ifTrue:[ |
1170 |
STCCompilationIncludes := '-I..\..\include -I..\..\libopengl -IC:\Borland\bcc55\Include'. |
|
1171 |
LinkArgs := '-L..\..\libbc -LC:\Borland\bcc55\Lib -r -c -ap -Tpd -Gi -w-dup'. |
|
1172 |
] ifFalse:[ |
|
1173 |
STCCompilationIncludes := '-I..\..\include -I..\..\libopengl -IC:\Borland\xxxxx\Include'. |
|
1174 |
LinkArgs := '-L..\..\libbc -LC:\Borland\xxxxx\Lib -r -c -ap -Tpd -Gi -w-dup'. |
|
1175 |
]. |
|
1658 | 1176 |
STCCompilationDefines := '-DWIN32'. |
1177 |
STCCompilationOptions := '+optinline +inlineNew'. |
|
1178 |
STCPath := '..\..\stc\stc.exe'. |
|
2011 | 1179 |
self useBorlandC ifTrue:[ |
1814 | 1180 |
CCPath := 'bcc32'. |
1181 |
MakeCommand := 'bmake'. |
|
1182 |
CCCompilationOptions := '-w-'. |
|
1668 | 1183 |
] ifFalse:[ |
1814 | 1184 |
CCPath := 'cl'. |
1185 |
MakeCommand := 'nmake'. |
|
1186 |
CCCompilationOptions := '-w-'. |
|
1668 | 1187 |
]. |
1658 | 1188 |
LinkCommand := 'ilink32'. |
1189 |
LibPath := ''. |
|
1660
c999eda0067a
stc flags moved to ParserFlags
Claus Gittinger <cg@exept.de>
parents:
1658
diff
changeset
|
1190 |
SearchedLibraries := #('import32.lib'). |
2061 | 1191 |
"/ SearchedLibraries := #('import32.lib' 'glu32.lib' 'opengl32.lib'). |
1658 | 1192 |
] ifFalse:[ |
1193 |
STCCompilationIncludes := '-I../../include'. |
|
1194 |
STCCompilationDefines := ''. |
|
1195 |
STCCompilationOptions := '+optinline +inlineNew'. |
|
1196 |
STCPath := '../../stc/stc'. |
|
1197 |
CCCompilationOptions := '-O'. |
|
2011 | 1198 |
ParserFlags useGnuC ifTrue:[ |
1668 | 1199 |
CCPath := 'gcc' |
1200 |
] ifFalse:[ |
|
1201 |
CCPath := 'cc' |
|
1202 |
]. |
|
1658 | 1203 |
LinkArgs := ''. |
1204 |
LinkCommand := 'ld'. |
|
1205 |
LibPath := ''. |
|
1660
c999eda0067a
stc flags moved to ParserFlags
Claus Gittinger <cg@exept.de>
parents:
1658
diff
changeset
|
1206 |
SearchedLibraries := #(). |
1814 | 1207 |
MakeCommand := 'make'. |
1658 | 1208 |
]. |
1209 |
||
1634 | 1210 |
" |
1211 |
ParserFlags initialize |
|
1212 |
" |
|
1773 | 1213 |
|
1814 | 1214 |
"Modified: / 09-08-2006 / 18:47:18 / fm" |
2011 | 1215 |
"Modified: / 15-03-2007 / 13:35:00 / cg" |
1634 | 1216 |
! ! |
1217 |
||
1658 | 1218 |
!ParserFlags methodsFor:'accessing-compilation control'! |
1219 |
||
1668 | 1220 |
allowExtensionsToPrivateClasses |
1221 |
^ allowExtensionsToPrivateClasses |
|
1222 |
! |
|
1223 |
||
1224 |
allowExtensionsToPrivateClasses:aBoolean |
|
1225 |
allowExtensionsToPrivateClasses := aBoolean |
|
1226 |
! |
|
1227 |
||
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1228 |
allowPossibleSTCCompilationProblems |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1229 |
^ allowPossibleSTCCompilationProblems |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1230 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1231 |
"Created: / 16-11-2006 / 14:24:54 / cg" |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1232 |
! |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1233 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1234 |
allowPossibleSTCCompilationProblems:aBoolean |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1235 |
allowPossibleSTCCompilationProblems := aBoolean |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1236 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1237 |
"Created: / 16-11-2006 / 14:24:56 / cg" |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1238 |
! |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1239 |
|
1658 | 1240 |
arraysAreImmutable |
1241 |
^ arraysAreImmutable |
|
1242 |
! |
|
1243 |
||
1244 |
arraysAreImmutable:aBoolean |
|
1245 |
arraysAreImmutable := aBoolean. |
|
1246 |
! |
|
1247 |
||
1717
fff182879ce2
qualified names again (VW7);
Claus Gittinger <cg@exept.de>
parents:
1713
diff
changeset
|
1248 |
flattenVisualWorksNamespaces |
fff182879ce2
qualified names again (VW7);
Claus Gittinger <cg@exept.de>
parents:
1713
diff
changeset
|
1249 |
^ true |
fff182879ce2
qualified names again (VW7);
Claus Gittinger <cg@exept.de>
parents:
1713
diff
changeset
|
1250 |
! |
fff182879ce2
qualified names again (VW7);
Claus Gittinger <cg@exept.de>
parents:
1713
diff
changeset
|
1251 |
|
1658 | 1252 |
stringsAreImmutable |
1253 |
^ stringsAreImmutable |
|
1254 |
! |
|
1255 |
||
1256 |
stringsAreImmutable:aBoolean |
|
1257 |
stringsAreImmutable := aBoolean. |
|
1258 |
! ! |
|
1259 |
||
1260 |
!ParserFlags methodsFor:'accessing-stc compilation control'! |
|
1261 |
||
1262 |
ccCompilationOptions |
|
1668 | 1263 |
^ ccCompilationOptions ? '' |
1658 | 1264 |
! |
1265 |
||
1266 |
ccCompilationOptions:something |
|
1267 |
ccCompilationOptions := something. |
|
1268 |
! |
|
1269 |
||
1270 |
ccPath |
|
1271 |
^ ccPath |
|
1272 |
! |
|
1273 |
||
1274 |
ccPath:something |
|
1275 |
ccPath := something. |
|
1276 |
! |
|
1277 |
||
1278 |
implicitSelfSends |
|
1279 |
^ implicitSelfSends |
|
1280 |
! |
|
1281 |
||
1282 |
implicitSelfSends:aBoolean |
|
1283 |
implicitSelfSends := aBoolean. |
|
1284 |
! |
|
1285 |
||
1286 |
libPath |
|
1287 |
^ libPath |
|
1288 |
! |
|
1289 |
||
1290 |
libPath:aString |
|
1291 |
libPath := aString |
|
1292 |
! |
|
1293 |
||
1294 |
linkArgs |
|
1295 |
^ linkArgs |
|
1296 |
! |
|
1297 |
||
1298 |
linkArgs:aString |
|
1299 |
linkArgs := aString |
|
1300 |
! |
|
1301 |
||
1302 |
linkCommand |
|
1303 |
^ linkCommand |
|
1304 |
! |
|
1305 |
||
1306 |
linkCommand:aString |
|
1307 |
linkCommand := aString |
|
1308 |
! |
|
1309 |
||
1898 | 1310 |
linkSharedArgs |
1311 |
^ linkSharedArgs |
|
1312 |
! |
|
1313 |
||
1314 |
linkSharedArgs:aString |
|
1315 |
linkSharedArgs := aString |
|
1316 |
! |
|
1317 |
||
1658 | 1318 |
searchedLibraries |
1319 |
^ searchedLibraries |
|
1320 |
! |
|
1321 |
||
1322 |
searchedLibraries:aString |
|
1323 |
searchedLibraries := aString |
|
1324 |
! |
|
1325 |
||
1326 |
stcCompilation |
|
1327 |
^ stcCompilation |
|
1328 |
! |
|
1329 |
||
1330 |
stcCompilation:something |
|
1331 |
stcCompilation := something. |
|
1332 |
! |
|
1333 |
||
1334 |
stcCompilationDefines |
|
1335 |
^ stcCompilationDefines |
|
1336 |
! |
|
1337 |
||
1338 |
stcCompilationDefines:something |
|
1339 |
stcCompilationDefines := something. |
|
1340 |
! |
|
1341 |
||
1342 |
stcCompilationIncludes |
|
1343 |
^ stcCompilationIncludes |
|
1344 |
! |
|
1345 |
||
1346 |
stcCompilationIncludes:something |
|
1347 |
stcCompilationIncludes := something. |
|
1348 |
! |
|
1349 |
||
1350 |
stcCompilationOptions |
|
1351 |
^ stcCompilationOptions |
|
1352 |
! |
|
1353 |
||
1354 |
stcCompilationOptions:something |
|
1355 |
stcCompilationOptions := something. |
|
1356 |
! |
|
1357 |
||
1358 |
stcKeepCIntermediate |
|
1359 |
^ stcKeepCIntermediate |
|
1360 |
! |
|
1361 |
||
1362 |
stcKeepCIntermediate:something |
|
1363 |
stcKeepCIntermediate := something. |
|
1364 |
! |
|
1365 |
||
1366 |
stcKeepOIntermediate |
|
1367 |
^ stcKeepOIntermediate |
|
1368 |
! |
|
1369 |
||
1370 |
stcKeepOIntermediate:something |
|
1371 |
stcKeepOIntermediate := something. |
|
1372 |
! |
|
1373 |
||
1374 |
stcKeepSTIntermediate |
|
1375 |
^ stcKeepSTIntermediate |
|
1376 |
! |
|
1377 |
||
1378 |
stcKeepSTIntermediate:something |
|
1379 |
stcKeepSTIntermediate := something. |
|
1380 |
! |
|
1381 |
||
1382 |
stcModulePath |
|
1383 |
^ stcModulePath |
|
1384 |
! |
|
1385 |
||
1386 |
stcModulePath:something |
|
1387 |
stcModulePath := something. |
|
1388 |
! |
|
1389 |
||
1390 |
stcPath |
|
1391 |
^ stcPath |
|
1392 |
! |
|
1393 |
||
1394 |
stcPath:something |
|
1395 |
stcPath := something. |
|
1396 |
! ! |
|
1397 |
||
1398 |
!ParserFlags methodsFor:'accessing-syntax-control'! |
|
1634 | 1399 |
|
1400 |
allowArrayIndexSyntaxExtension |
|
1401 |
^ allowArrayIndexSyntaxExtension |
|
1402 |
! |
|
1403 |
||
1404 |
allowArrayIndexSyntaxExtension:aBoolean |
|
1405 |
allowArrayIndexSyntaxExtension := aBoolean. |
|
1406 |
! |
|
1407 |
||
2306 | 1408 |
allowCaretAsBinop |
1409 |
^ allowCaretAsBinop |
|
1410 |
! |
|
1411 |
||
1412 |
allowCaretAsBinop:aBoolean |
|
1413 |
allowCaretAsBinop := aBoolean. |
|
1414 |
! |
|
1415 |
||
1634 | 1416 |
allowDollarInIdentifier |
1417 |
^ allowDollarInIdentifier |
|
1418 |
! |
|
1419 |
||
1420 |
allowDollarInIdentifier:aBoolean |
|
1421 |
allowDollarInIdentifier := aBoolean. |
|
1422 |
! |
|
1423 |
||
1424 |
allowDolphinExtensions |
|
1425 |
^ allowDolphinExtensions |
|
1426 |
! |
|
1427 |
||
1428 |
allowDolphinExtensions:aBoolean |
|
1429 |
allowDolphinExtensions := aBoolean |
|
1430 |
! |
|
1431 |
||
1432 |
allowDomainVariables |
|
1433 |
^ allowDomainVariables |
|
1434 |
! |
|
1435 |
||
1436 |
allowDomainVariables:aBoolean |
|
1437 |
allowDomainVariables := aBoolean. |
|
1438 |
! |
|
1439 |
||
1950 | 1440 |
allowEmptyStatements |
1441 |
^ allowEmptyStatements ? false |
|
1442 |
||
1443 |
"Created: / 20-11-2006 / 13:56:14 / cg" |
|
1444 |
! |
|
1445 |
||
1446 |
allowEmptyStatements:aBoolean |
|
1447 |
allowEmptyStatements := aBoolean. |
|
1448 |
||
1449 |
"Created: / 20-11-2006 / 14:26:48 / cg" |
|
1450 |
! |
|
1451 |
||
1634 | 1452 |
allowExtendedBinarySelectors |
1453 |
^ allowExtendedBinarySelectors |
|
1454 |
! |
|
1455 |
||
1456 |
allowExtendedBinarySelectors:aBoolean |
|
1457 |
allowExtendedBinarySelectors := aBoolean. |
|
1458 |
! |
|
1459 |
||
1460 |
allowExtendedSTXSyntax |
|
1461 |
^ allowExtendedSTXSyntax |
|
1462 |
! |
|
1463 |
||
1464 |
allowExtendedSTXSyntax:something |
|
1465 |
allowExtendedSTXSyntax := something. |
|
1466 |
! |
|
1467 |
||
1468 |
allowFixedPointLiterals |
|
1469 |
^ allowFixedPointLiterals |
|
1470 |
! |
|
1471 |
||
1472 |
allowFixedPointLiterals:something |
|
1473 |
allowFixedPointLiterals := something. |
|
1474 |
! |
|
1475 |
||
1476 |
allowFunctionCallSyntaxForBlockEvaluation |
|
1477 |
^ allowFunctionCallSyntaxForBlockEvaluation |
|
1478 |
! |
|
1479 |
||
1480 |
allowFunctionCallSyntaxForBlockEvaluation:aBoolean |
|
1481 |
allowFunctionCallSyntaxForBlockEvaluation := aBoolean. |
|
1482 |
! |
|
1483 |
||
1706
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1484 |
allowHashAsBinarySelector |
1713 | 1485 |
^ allowHashAsBinarySelector |
1706
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1486 |
! |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1487 |
|
1634 | 1488 |
allowLazyValueExtension |
1489 |
^ allowLazyValueExtension |
|
1490 |
! |
|
1491 |
||
1492 |
allowLazyValueExtension:something |
|
1493 |
allowLazyValueExtension := something. |
|
1494 |
! |
|
1495 |
||
1496 |
allowLiteralNameSpaceSymbols |
|
1497 |
^ allowLiteralNameSpaceSymbols |
|
1498 |
! |
|
1499 |
||
1500 |
allowLiteralNameSpaceSymbols:aBoolean |
|
1501 |
allowLiteralNameSpaceSymbols := aBoolean |
|
1502 |
! |
|
1503 |
||
1504 |
allowLocalVariableDeclarationWithInitializerExpression |
|
1505 |
^ allowLocalVariableDeclarationWithInitializerExpression |
|
1506 |
! |
|
1507 |
||
1508 |
allowLocalVariableDeclarationWithInitializerExpression:aBoolean |
|
1509 |
allowLocalVariableDeclarationWithInitializerExpression := aBoolean. |
|
1510 |
! |
|
1511 |
||
1706
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1512 |
allowNationalCharactersInIdentifier |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1513 |
^ allowNationalCharactersInIdentifier |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1514 |
! |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1515 |
|
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1516 |
allowNationalCharactersInIdentifier:aBoolean |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1517 |
allowNationalCharactersInIdentifier := aBoolean |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1518 |
! |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1519 |
|
1634 | 1520 |
allowOldStyleAssignment |
1521 |
^ allowOldStyleAssignment |
|
1522 |
! |
|
1523 |
||
1524 |
allowOldStyleAssignment:aBoolean |
|
1525 |
allowOldStyleAssignment := aBoolean |
|
1526 |
! |
|
1527 |
||
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1528 |
allowPeriodInSymbol |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1529 |
^ allowPeriodInSymbol |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1530 |
! |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1531 |
|
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1532 |
allowPeriodInSymbol:aBoolean |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1533 |
allowPeriodInSymbol := aBoolean |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1534 |
! |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1535 |
|
1634 | 1536 |
allowQualifiedNames |
1537 |
^ allowQualifiedNames |
|
1538 |
! |
|
1539 |
||
1540 |
allowQualifiedNames:aBoolean |
|
1541 |
allowQualifiedNames := aBoolean. |
|
1542 |
! |
|
1543 |
||
1544 |
allowReservedWordsAsSelectors |
|
1545 |
^ allowReservedWordsAsSelectors |
|
1546 |
! |
|
1547 |
||
1548 |
allowReservedWordsAsSelectors:aBoolean |
|
1549 |
allowReservedWordsAsSelectors := aBoolean. |
|
1550 |
! |
|
1551 |
||
1703 | 1552 |
allowSTVExtensions |
1553 |
"return true, if support for ST/V extensions is enabled." |
|
1554 |
||
1555 |
^ allowSTVExtensions |
|
1556 |
! |
|
1557 |
||
1701 | 1558 |
allowSTVPrimitives |
1559 |
"return true, if support for ST/V primitives is enabled." |
|
1560 |
||
1561 |
^ allowSTVPrimitives |
|
1562 |
! |
|
1563 |
||
1708
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1564 |
allowSTXEOLComments |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1565 |
^ allowSTXEOLComments |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1566 |
! |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1567 |
|
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1568 |
allowSTXEOLComments:aBoolean |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1569 |
allowSTXEOLComments := aBoolean. |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1570 |
|
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1571 |
" |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1572 |
ParserFlags allowSTXEOLComments:false |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1573 |
ParserFlags allowSTXEOLComments:true |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1574 |
" |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1575 |
! |
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1576 |
|
1634 | 1577 |
allowSqueakExtensions |
1578 |
"return true, if support for squeak extensions |
|
1579 |
computed arrays { .., } |
|
1580 |
c/java style arguments in message sends rec foo(arg1, ... argN) |
|
1581 |
is enabled." |
|
1582 |
||
1583 |
^ allowSqueakExtensions |
|
1584 |
! |
|
1585 |
||
1586 |
allowSqueakExtensions:aBoolean |
|
1587 |
"this allows turning on/off support for squeak extensions: |
|
1588 |
computed arrays { .., } |
|
1589 |
c/java style arguments in message sends rec foo(arg1, ... argN) |
|
1590 |
" |
|
1591 |
||
1592 |
allowSqueakExtensions := aBoolean |
|
1593 |
! |
|
1594 |
||
1689 | 1595 |
allowSqueakPrimitives |
1596 |
"return true, if support for squeak primitives is enabled." |
|
1597 |
||
1598 |
^ allowSqueakPrimitives |
|
1599 |
! |
|
1600 |
||
1601 |
allowSqueakPrimitives:aBoolean |
|
1602 |
"this allows turning on/off support for squeak primitives" |
|
1603 |
||
1604 |
allowSqueakPrimitives := aBoolean |
|
1605 |
! |
|
1606 |
||
1634 | 1607 |
allowUnderscoreInIdentifier |
1608 |
^ allowUnderscoreInIdentifier |
|
1609 |
! |
|
1610 |
||
1611 |
allowUnderscoreInIdentifier:aBoolean |
|
1612 |
allowUnderscoreInIdentifier := aBoolean |
|
1613 |
! |
|
1614 |
||
1615 |
allowVariableReferences |
|
1616 |
^ allowVariableReferences |
|
1617 |
! |
|
1618 |
||
1619 |
allowVariableReferences:aBoolean |
|
1620 |
allowVariableReferences := aBoolean. |
|
1621 |
! |
|
1622 |
||
1655 | 1623 |
allowVisualAgeESSymbolLiterals |
1624 |
^ allowVisualAgeESSymbolLiterals |
|
1625 |
! |
|
1626 |
||
1627 |
allowVisualAgeESSymbolLiterals:aBoolean |
|
1628 |
allowVisualAgeESSymbolLiterals := aBoolean. |
|
1689 | 1629 |
! |
1630 |
||
1631 |
allowVisualAgePrimitives |
|
1632 |
"return true, if support for V'Age primitives is enabled." |
|
1633 |
||
1634 |
^ allowVisualAgePrimitives |
|
1635 |
! |
|
1636 |
||
1637 |
allowVisualAgePrimitives:aBoolean |
|
1638 |
"this allows turning on/off support for V'Age primitives" |
|
1639 |
||
1640 |
allowVisualAgePrimitives := aBoolean |
|
1773 | 1641 |
! |
1642 |
||
1643 |
allowVisualWorksMethodAnnotations |
|
1644 |
"return true, if support for V'Works extended primitive syntax for method annotations." |
|
1645 |
||
1646 |
^ allowVisualWorksMethodAnnotations |
|
1647 |
||
1648 |
"Created: / 07-07-2006 / 15:48:30 / cg" |
|
1649 |
! |
|
1650 |
||
1651 |
allowVisualWorksMethodAnnotations:aBoolean |
|
1652 |
"turn on/off support for V'Works extended primitive syntax for method annotations." |
|
1653 |
||
1654 |
^ allowVisualWorksMethodAnnotations := aBoolean |
|
1655 |
||
1656 |
"Created: / 07-07-2006 / 15:49:03 / cg" |
|
1658 | 1657 |
! ! |
1634 | 1658 |
|
1658 | 1659 |
!ParserFlags methodsFor:'accessing-warning-control'! |
1634 | 1660 |
|
1652 | 1661 |
warnAboutBadComments |
1662 |
^ warnAboutBadComments |
|
1663 |
! |
|
1664 |
||
1665 |
warnAboutBadComments:aBoolean |
|
1666 |
warnAboutBadComments := aBoolean. |
|
1667 |
! |
|
1668 |
||
1811 | 1669 |
warnAboutNonLowercaseLocalVariableNames |
1670 |
^ warnAboutNonLowercaseLocalVariableNames |
|
1740 | 1671 |
! |
1672 |
||
1811 | 1673 |
warnAboutNonLowercaseLocalVariableNames:aBoolean |
1674 |
warnAboutNonLowercaseLocalVariableNames := aBoolean. |
|
1740 | 1675 |
! |
1676 |
||
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1677 |
warnAboutPeriodInSymbol |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1678 |
^ warnAboutPeriodInSymbol |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1679 |
! |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1680 |
|
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1681 |
warnAboutPeriodInSymbol:aBoolean |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1682 |
warnAboutPeriodInSymbol := aBoolean. |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1683 |
! |
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1684 |
|
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1685 |
warnAboutPossibleSTCCompilationProblems |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1686 |
^ warnAboutPossibleSTCCompilationProblems |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1687 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1688 |
"Created: / 16-11-2006 / 14:24:38 / cg" |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1689 |
! |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1690 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1691 |
warnAboutPossibleSTCCompilationProblems:aBoolean |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1692 |
warnAboutPossibleSTCCompilationProblems := aBoolean. |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1693 |
|
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1694 |
"Created: / 16-11-2006 / 14:24:40 / cg" |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1695 |
! |
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1696 |
|
2121 | 1697 |
warnAboutPossiblyUnimplementedSelectors |
1698 |
^ warnAboutPossiblyUnimplementedSelectors |
|
1699 |
! |
|
1700 |
||
1701 |
warnAboutPossiblyUnimplementedSelectors:aBoolean |
|
1702 |
warnAboutPossiblyUnimplementedSelectors := aBoolean. |
|
1703 |
! |
|
1704 |
||
2073
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1705 |
warnAboutReferenceToPrivateClass |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1706 |
"controls generation of warning messages when a private class is referenced" |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1707 |
|
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1708 |
^ warnAboutReferenceToPrivateClass |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1709 |
! |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1710 |
|
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1711 |
warnAboutReferenceToPrivateClass:aBoolean |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1712 |
"controls generation of warning messages when a private class is referenced" |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1713 |
|
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1714 |
warnAboutReferenceToPrivateClass := aBoolean |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1715 |
! |
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1716 |
|
2079
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1717 |
warnAboutShortLocalVariableNames |
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1718 |
^ warnAboutShortLocalVariableNames |
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1719 |
! |
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1720 |
|
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1721 |
warnAboutShortLocalVariableNames:aBoolean |
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1722 |
warnAboutShortLocalVariableNames := aBoolean. |
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1723 |
! |
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1724 |
|
1634 | 1725 |
warnAboutVariableNameConventions |
1726 |
^ warnAboutVariableNameConventions |
|
1727 |
! |
|
1728 |
||
1729 |
warnAboutVariableNameConventions:aBoolean |
|
1730 |
warnAboutVariableNameConventions := aBoolean. |
|
1731 |
! |
|
1732 |
||
1733 |
warnAboutWrongVariableNames |
|
1734 |
^ warnAboutWrongVariableNames |
|
1735 |
! |
|
1736 |
||
1737 |
warnAboutWrongVariableNames:aBoolean |
|
1738 |
warnAboutWrongVariableNames := aBoolean. |
|
1739 |
! |
|
1740 |
||
1741 |
warnCommonMistakes |
|
1742 |
^ warnCommonMistakes |
|
1743 |
! |
|
1744 |
||
1745 |
warnCommonMistakes:aBoolean |
|
1746 |
warnCommonMistakes := aBoolean. |
|
1747 |
! |
|
1748 |
||
1749 |
warnDollarInIdentifier |
|
1750 |
^ warnDollarInIdentifier |
|
1751 |
! |
|
1752 |
||
1753 |
warnDollarInIdentifier:aBoolean |
|
1754 |
warnDollarInIdentifier := aBoolean. |
|
1755 |
! |
|
1756 |
||
1638 | 1757 |
warnHiddenVariables |
1758 |
^ warnHiddenVariables |
|
1759 |
! |
|
1760 |
||
1761 |
warnHiddenVariables:aBoolean |
|
1762 |
warnHiddenVariables := aBoolean. |
|
1763 |
! |
|
1764 |
||
1682 | 1765 |
warnInconsistentReturnValues |
1766 |
^ warnInconsistentReturnValues |
|
1767 |
! |
|
1768 |
||
1769 |
warnInconsistentReturnValues:aBoolean |
|
1770 |
warnInconsistentReturnValues := aBoolean. |
|
1771 |
! |
|
1772 |
||
1634 | 1773 |
warnOldStyleAssignment |
1774 |
^ warnOldStyleAssignment |
|
1775 |
! |
|
1776 |
||
1777 |
warnOldStyleAssignment:aBoolean |
|
1778 |
warnOldStyleAssignment := aBoolean. |
|
1779 |
! |
|
1780 |
||
1781 |
warnPossibleIncompatibilities |
|
2057 | 1782 |
"holds true, if possible incompatibilities (with other ST systems) |
1783 |
are to be warned about" |
|
1784 |
||
1634 | 1785 |
^ warnPossibleIncompatibilities |
1786 |
! |
|
1787 |
||
1788 |
warnPossibleIncompatibilities:aBoolean |
|
2057 | 1789 |
"holds true, if possible incompatibilities (with other ST systems) |
1790 |
are to be warned about" |
|
1791 |
||
1634 | 1792 |
warnPossibleIncompatibilities := aBoolean. |
1793 |
! |
|
1794 |
||
1795 |
warnST80Directives |
|
1796 |
^ warnST80Directives |
|
1797 |
! |
|
1798 |
||
1799 |
warnST80Directives:something |
|
1800 |
warnST80Directives := something. |
|
1801 |
! |
|
1802 |
||
1803 |
warnSTXHereExtensionUsed |
|
1804 |
^ warnSTXHereExtensionUsed |
|
1805 |
! |
|
1806 |
||
1807 |
warnSTXHereExtensionUsed:aBoolean |
|
1808 |
warnSTXHereExtensionUsed := aBoolean. |
|
1809 |
! |
|
1810 |
||
1811 |
warnSTXNameSpaceUse |
|
1812 |
^ warnSTXNameSpaceUse |
|
1813 |
! |
|
1814 |
||
1815 |
warnSTXNameSpaceUse:aBoolean |
|
1816 |
warnSTXNameSpaceUse := aBoolean. |
|
1817 |
! |
|
1818 |
||
1819 |
warnSTXSpecialComment |
|
1820 |
^ warnSTXSpecialComment |
|
1821 |
! |
|
1822 |
||
1823 |
warnSTXSpecialComment:aBoolean |
|
1824 |
warnSTXSpecialComment := aBoolean. |
|
1825 |
! |
|
1826 |
||
1827 |
warnUndeclared |
|
1828 |
^ warnUndeclared |
|
1829 |
! |
|
1830 |
||
1831 |
warnUndeclared:aBoolean |
|
1832 |
warnUndeclared := aBoolean. |
|
1833 |
! |
|
1834 |
||
1835 |
warnUnderscoreInIdentifier |
|
1836 |
^ warnUnderscoreInIdentifier |
|
1837 |
! |
|
1838 |
||
1839 |
warnUnderscoreInIdentifier:aBoolean |
|
1840 |
warnUnderscoreInIdentifier := aBoolean. |
|
1841 |
! |
|
1842 |
||
1843 |
warnUnusedVars |
|
1844 |
^ warnUnusedVars |
|
1845 |
! |
|
1846 |
||
1847 |
warnUnusedVars:aBoolean |
|
1848 |
warnUnusedVars := aBoolean. |
|
1662 | 1849 |
! |
1850 |
||
1851 |
warnings |
|
1852 |
^ warnings |
|
1853 |
! |
|
1854 |
||
1855 |
warnings:something |
|
1856 |
warnings := something. |
|
1634 | 1857 |
! ! |
1858 |
||
1859 |
!ParserFlags methodsFor:'initialization'! |
|
1860 |
||
1861 |
initialize |
|
1662 | 1862 |
warnings := Warnings. |
1634 | 1863 |
warnUndeclared := WarnUndeclared. |
1864 |
warnUnusedVars := WarnUnusedVars. |
|
1865 |
warnST80Directives := WarnST80Directives. |
|
1866 |
warnSTXSpecialComment := WarnSTXSpecials. |
|
1867 |
warnSTXNameSpaceUse := WarnSTXSpecials. |
|
1868 |
warnSTXHereExtensionUsed := WarnSTXSpecials. |
|
1869 |
warnUnderscoreInIdentifier := WarnUnderscoreInIdentifier. |
|
1870 |
warnDollarInIdentifier := WarnDollarInIdentifier. |
|
1871 |
warnOldStyleAssignment := WarnOldStyleAssignment. |
|
1872 |
warnCommonMistakes := WarnCommonMistakes. |
|
1873 |
warnPossibleIncompatibilities := WarnPossibleIncompatibilities. |
|
1874 |
warnAboutVariableNameConventions := WarnAboutVariableNameConventions. |
|
1875 |
warnAboutWrongVariableNames := WarnAboutWrongVariableNames. |
|
1652 | 1876 |
warnAboutBadComments := WarnAboutBadComments. |
2073
efd507565894
+warnAboutReferenceToPrivateClass
Claus Gittinger <cg@exept.de>
parents:
2061
diff
changeset
|
1877 |
warnAboutReferenceToPrivateClass := WarnAboutReferenceToPrivateClass. |
1638 | 1878 |
warnHiddenVariables := WarnHiddenVariables. |
1682 | 1879 |
warnInconsistentReturnValues := WarnInconsistentReturnValues. |
1811 | 1880 |
warnAboutNonLowercaseLocalVariableNames := WarnAboutNonLowercaseLocalVariableNames. |
2079
0625ff661e53
+warnAboutShortVariableNames
Claus Gittinger <cg@exept.de>
parents:
2073
diff
changeset
|
1881 |
warnAboutShortLocalVariableNames := WarnAboutShortLocalVariableNames. |
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1882 |
warnAboutPossibleSTCCompilationProblems := WarnAboutPossibleSTCCompilationProblems. |
2121 | 1883 |
warnAboutPossiblyUnimplementedSelectors := WarnAboutPossiblyUnimplementedSelectors. |
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1884 |
warnAboutPeriodInSymbol := WarnAboutPeriodInSymbol. |
1634 | 1885 |
|
1886 |
allowUnderscoreInIdentifier := AllowUnderscoreInIdentifier. |
|
1887 |
allowDollarInIdentifier := AllowDollarInIdentifier. |
|
1888 |
allowOldStyleAssignment := AllowOldStyleAssignment. |
|
1889 |
allowSqueakExtensions := AllowSqueakExtensions. |
|
1890 |
allowDolphinExtensions := AllowDolphinExtensions. |
|
1891 |
allowLiteralNameSpaceSymbols := AllowLiteralNameSpaceSymbols. |
|
1892 |
allowExtendedBinarySelectors := AllowExtendedBinarySelectors. |
|
2306 | 1893 |
allowCaretAsBinop := AllowCaretAsBinop. |
1634 | 1894 |
allowFunctionCallSyntaxForBlockEvaluation := AllowFunctionCallSyntaxForBlockEvaluation. |
1895 |
allowLocalVariableDeclarationWithInitializerExpression := AllowLocalVariableDeclarationWithInitializerExpression. |
|
1896 |
allowDomainVariables := AllowDomainVariables. |
|
1897 |
allowArrayIndexSyntaxExtension := AllowArrayIndexSyntaxExtension. |
|
1898 |
allowReservedWordsAsSelectors := AllowReservedWordsAsSelectors. |
|
1899 |
allowVariableReferences := AllowVariableReferences. |
|
1900 |
allowLazyValueExtension := AllowLazyValueExtension. |
|
1901 |
allowFixedPointLiterals := AllowFixedPointLiterals. |
|
1902 |
allowExtendedSTXSyntax := AllowExtendedSTXSyntax. |
|
1903 |
allowQualifiedNames := AllowQualifiedNames. |
|
1655 | 1904 |
allowVisualAgeESSymbolLiterals := AllowVisualAgeESSymbolLiterals. |
1668 | 1905 |
allowExtensionsToPrivateClasses := AllowExtensionsToPrivateClasses. |
1689 | 1906 |
allowVisualAgePrimitives := AllowVisualAgePrimitives. |
1907 |
allowSqueakPrimitives := AllowSqueakPrimitives. |
|
1700 | 1908 |
allowSTVPrimitives := AllowSTVPrimitives. |
1702 | 1909 |
allowSTVExtensions := AllowSTVExtensions. |
1706
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1910 |
allowNationalCharactersInIdentifier := AllowNationalCharactersInIdentifier. |
685cea395a8c
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1704
diff
changeset
|
1911 |
allowHashAsBinarySelector := AllowHashAsBinarySelector. |
1708
eb71a302895e
more support for filein of ST/V code
Claus Gittinger <cg@exept.de>
parents:
1706
diff
changeset
|
1912 |
allowSTXEOLComments := AllowSTXEOLComments. |
1773 | 1913 |
allowVisualWorksMethodAnnotations := AllowVisualWorksMethodAnnotations. |
1947
a5429732842a
warn/allow stc-uncompilable code.
Claus Gittinger <cg@exept.de>
parents:
1940
diff
changeset
|
1914 |
allowPossibleSTCCompilationProblems := AllowPossibleSTCCompilationProblems. |
1950 | 1915 |
allowEmptyStatements := AllowEmptyStatements. |
2179
5ccb29e1233a
allowPeriodInSymbol - to read old st80/squeak code
Claus Gittinger <cg@exept.de>
parents:
2145
diff
changeset
|
1916 |
allowPeriodInSymbol := AllowPeriodInSymbol. |
1634 | 1917 |
|
1918 |
arraysAreImmutable := ArraysAreImmutable ? true. |
|
1919 |
stringsAreImmutable := StringsAreImmutable ? true. |
|
1920 |
implicitSelfSends := ImplicitSelfSends ? false. |
|
1921 |
||
1658 | 1922 |
stcKeepCIntermediate := STCKeepCIntermediate. |
1923 |
stcKeepOIntermediate := STCKeepOIntermediate. |
|
1924 |
stcKeepSTIntermediate := STCKeepSTIntermediate. |
|
1925 |
stcModulePath := STCModulePath. |
|
1926 |
stcCompilation := STCCompilation. |
|
1927 |
stcCompilationIncludes := STCCompilationIncludes. |
|
1928 |
stcCompilationDefines := STCCompilationDefines. |
|
1929 |
stcCompilationOptions := STCCompilationOptions. |
|
1930 |
stcPath := STCPath. |
|
1931 |
ccCompilationOptions := CCCompilationOptions. |
|
1932 |
ccPath := CCPath. |
|
1933 |
linkArgs := LinkArgs. |
|
1934 |
linkCommand := LinkCommand. |
|
1935 |
libPath := LibPath. |
|
1936 |
searchedLibraries := SearchedLibraries. |
|
1937 |
||
1634 | 1938 |
" |
1939 |
ParserFlags initialize. |
|
1940 |
self new inspect. |
|
1941 |
" |
|
1773 | 1942 |
|
1950 | 1943 |
"Modified: / 20-11-2006 / 14:28:02 / cg" |
1634 | 1944 |
! ! |
1945 |
||
1946 |
!ParserFlags class methodsFor:'documentation'! |
|
1947 |
||
1948 |
version |
|
2306 | 1949 |
^ '$Header: /cvs/stx/stx/libcomp/ParserFlags.st,v 1.49 2009-12-07 19:41:07 cg Exp $' |
2218
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
1950 |
! |
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
1951 |
|
51ac45ab36a2
changed: #allowExtendedBinarySelectors
Claus Gittinger <cg@exept.de>
parents:
2179
diff
changeset
|
1952 |
version_CVS |
2306 | 1953 |
^ '$Header: /cvs/stx/stx/libcomp/ParserFlags.st,v 1.49 2009-12-07 19:41:07 cg Exp $' |
1634 | 1954 |
! ! |
1955 |
||
1956 |
ParserFlags initialize! |