Add a slice.suffix method.

This commit is contained in:
Nigel Tao committed 2017-09-22 14:12:54 +10:00
1 parent 51f2b183a2
commit 2fb9972bb9
10 files changed
+176 -2

No files matched your search

+1 -1
View File
@@ -689,7 +689,7 @@ func (q *checker) bcheckExprOther(n *a.Expr, depth uint32) (*big.Int, *big.Int,
return zero, bitMask(int(aMax.Int64())), nil
}
// TODO: delete this hack that only matches "foo.is_suspension(etc)".
if isIsErrorOKSuspension(q.tm, n, t.KeyIsSuspension) {
if isIsErrorOKSuspension(q.tm, n, t.KeyIsSuspension) || isIsPrefixSuffix(q.tm, n, t.KeySuffix) {
return nil, nil, nil
}
// TODO: delete this hack that only matches "foo.set_literal_width(etc)".