Ticket #141: turbo-plus.patch
File turbo-plus.patch, 4.1 KB (added by hopscc, 15 years ago) |
---|
-
Source/CommandLine.cobra
1269 1269 if options.getDefault('debug', '') not in ['', '0', '-'] and not options.isSpecified('debugging-tips') 1270 1270 options['debugging-tips'] = false 1271 1271 if options.boolValue('turbo') 1272 options['contracts'] = 'none' 1273 options['include-asserts'] = false 1274 options['include-nil-checks'] = false 1275 options['include-tests'] = false 1276 options['include-traces'] = false 1277 options['optimize'] = true 1272 if not options.isSpecified('contracts') 1273 options['contracts'] = 'none' 1274 if not options.isSpecified('include-asserts') 1275 options['include-asserts'] = false 1276 if not options.isSpecified('include-nil-checks') 1277 options['include-nil-checks'] = false 1278 if not options.isSpecified('include-tests') 1279 options['include-tests'] = false 1280 if not options.isSpecified('include-traces') 1281 options['include-traces'] = false 1282 if not options.isSpecified('optimize') 1283 options['optimize'] = true 1278 1284 1279 1285 def _interpretValue(valueStr as String, spec as OptionSpec) as dynamic? 1280 1286 value as dynamic? -
Tests/700-command-line/603-turbo-plus.cobra
1 # test -turbo with one of suboptions overidden 2 3 use System.Diagnostics 4 5 class Test 6 7 def main is shared 8 Test().run 9 10 def run 11 sub = '603a-sub.cobra' 12 ite = '-include-tests:yes' 13 itr = '-include-traces:yes' 14 ia = '-include-asserts:yes' 15 16 output = .runCobraExe('-turbo [sub]') 17 try 18 assert '** Test' not in output 19 assert 'trace:' not in output 20 assert 'AssertException' not in output 21 assert 'OKThxBai' in output 22 success 23 print '-turbo OK' 24 25 output = .runCobraExe('-turbo [ite] [sub]') 26 try 27 assert '** Test' in output 28 assert 'trace:' not in output 29 assert 'AssertException' not in output 30 assert 'OKThxBai' in output 31 success 32 print '-turbo [ite] OK' 33 34 output = .runCobraExe('-turbo [itr] [sub]') 35 try 36 assert '** Test' not in output 37 assert 'trace: a=99;' in output 38 assert 'AssertException' not in output 39 assert 'OKThxBai' in output 40 success 41 print '-turbo [itr] OK' 42 43 output = .runCobraExe('-turbo [ia] [sub]') 44 try 45 assert '** Test' not in output 46 assert 'trace:' not in output 47 assert 'AssertException thrown' in output 48 assert 'OKThxBai' in output 49 success 50 print '-turbo [ia] OK' 51 52 output = .runCobraExe('-turbo [ia] [itr] [ite] [sub]') 53 try 54 assert '** Test' in output 55 assert 'trace:' in output 56 assert 'AssertException thrown' in output 57 assert 'OKThxBai' in output 58 success 59 print '-turbo [ia] [itr] [ite] OK' 60 61 def runCobraExe(args as String) as String 62 p as System.Diagnostics.Process? 63 return CobraCore.runCobraExe(args, out p) -
Tests/700-command-line/603a-sub.cobra
1 # .skip. 2 # executed by 603-turbo-plus 3 class Test 4 def main is shared 5 test 6 print '** Test' 7 body 8 a = 99 9 trace a 10 print 'OKThxBai' 11 try 12 assert a == 100 13 catch AssertException 14 print 'AssertException thrown' -
Developer/IntermediateReleaseNotes.text
392 392 * Fixed: Cobra gives an inscrutable error message for numeric for-loops that have incompatible numeric types. ticket:165 393 393 394 394 * Fixed: Improper codegen for static constructors. ticket:169 395 396 * Fixed: Cannot effectively put more options after -turbo. ticket:141