Files
swift-mirror/test/Misc/expression_too_complex.swift
William Dillon 7be98b0e73 Reduce memory threshold for expression_too_complex
The 5000 byte treshold is too generous on 32-bit systems to trigger the expression too complex test.  Reducing it to 4000 causes the compiler to bail (as expected) on these platforms while retaining the expected behavior on 64-bit systems.
2016-02-10 21:38:22 +00:00

13 lines
416 B
Swift

// RUN: %target-parse-verify-swift -solver-memory-threshold 4000
var x = [1, 2, 3, 4.5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18 ,19] // expected-error{{expression was too complex to be solved in reasonable time; consider breaking up the expression into distinct sub-expressions}}
// No errors should appear below as a result of the error above.
var y = 10
var z = 10 + 10
class C {}
var c = C()
var d = c