Skip to content

Commit

Permalink
Commit missing parts of 919a49b.
Browse files Browse the repository at this point in the history
whitequark committed Feb 25, 2016
1 parent f838b8b commit 6bd16e4
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion artiq/test/lit/inferencer/error_with_arity.py
Original file line number Diff line number Diff line change
@@ -9,7 +9,7 @@ def __exit__(self, n1, n2):
pass

def foo():
# CHECK-L: ${LINE:+2}: error: function '__enter__(self:<instance contextmgr {}>, n1:'a)->NoneType delay('b)' must accept 1 positional argument and no optional arguments
# CHECK-L: ${LINE:+2}: error: function '__enter__(self:<instance contextmgr>, n1:'a)->NoneType delay('b)' must accept 1 positional argument and no optional arguments
# CHECK-L: ${LINE:+1}: error: function '__exit__(self:<instance contextmgr>, n1:'c, n2:'d)->NoneType delay('e)' must accept 4 positional arguments and no optional arguments
with contextmgr():
pass
2 changes: 1 addition & 1 deletion artiq/test/lit/inferencer/error_with_exn.py
Original file line number Diff line number Diff line change
@@ -11,6 +11,6 @@ def __exit__(self, n1, n2, n3):

def foo():
# CHECK-L: ${LINE:+2}: error: cannot unify int(width='a) with NoneType
# CHECK-L: ${LINE:+1}: note: exception handling via context managers is not supported; the argument 'n3' of function '__exit__(self:<instance contextmgr {}>, n1:NoneType, n2:NoneType, n3:int(width='a))->NoneType delay('b)' will always be None
# CHECK-L: ${LINE:+1}: note: exception handling via context managers is not supported; the argument 'n3' of function '__exit__(self:<instance contextmgr>, n1:NoneType, n2:NoneType, n3:int(width='a))->NoneType delay('b)' will always be None
with contextmgr():
pass
2 changes: 1 addition & 1 deletion artiq/test/lit/inferencer/error_with_self.py
Original file line number Diff line number Diff line change
@@ -11,7 +11,7 @@ def __exit__(self, n1, n2, n3):
def foo():
contextmgr.__enter__(1)
# CHECK-L: ${LINE:+3}: error: cannot unify <instance contextmgr> with int(width='a) while inferring the type for self argument
# CHECK-L: ${LINE:+2}: note: expression of type <instance contextmgr {}>
# CHECK-L: ${LINE:+2}: note: expression of type <instance contextmgr>
# CHECK-L: ${LINE:+1}: note: reference to an instance with a method '__enter__(self:int(width='a))->NoneType delay('b)'
with contextmgr():
pass
2 changes: 1 addition & 1 deletion artiq/test/lit/iodelay/class.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# RUN: %python -m artiq.compiler.testbench.signature %s >%t
# RUN: OutputCheck %s --file-to-check=%t

# CHECK-L: g: (i:<instance c {}>)->NoneType delay(1000000 mu)
# CHECK-L: g: (i:<instance c>)->NoneType delay(1000000 mu)
def g(i):
i.f(1.0)

0 comments on commit 6bd16e4

Please sign in to comment.