

def test_restrict():
    from cffi import model
    for (input, expected_output) in [('int a;', False), ('restrict int a;', True), ('int *a;', False)]:
        ffi = FFI()
        ffi.cdef(input)
        (tp, quals) = ffi._parser._declarations['variable a']
        assert (bool((tp & model.Q_RESTRICT)) == expected_output)

dataset/ETHPy150Open johncsnyder/SwiftKitten/cffi/testing/cffi0/test_parsing.py test_restrict/VarMisuse@76/108 `quals`->`tp`