Did I find the right examples for you? yes no

All Samples(391)  |  Call(354)  |  Derive(2)  |  Import(35)

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/annotation/unaryop.py   plexnet(Download)
 
from types import MethodType
from pypy.annotation.model import \
     SomeObject, SomeInteger, SomeBool, SomeString, SomeChar, SomeList, \
     SomeDict, SomeTuple, SomeImpossibleValue, \
    def len(obj):
        return SomeInteger(nonneg=True)
 
    def is_true_behavior(obj, s):
        if obj.is_immutable_constant():
    def int(obj):
        return SomeInteger()
 
    def float(obj):
        return SomeFloat()
class __extend__(SomeInteger):
 
    def invert(self):
        return SomeInteger(knowntype=self.knowntype)
    invert.can_only_throw = []

src/s/y/Sypy-HEAD/annotation/unaryop.py   Sypy(Download)
 
from types import MethodType
from pypy.annotation.model import \
     SomeObject, SomeInteger, SomeBool, SomeString, SomeChar, SomeList, \
     SomeDict, SomeTuple, SomeImpossibleValue, SomeUnicodeCodePoint, \
    def len(obj):
        return SomeInteger(nonneg=True)
 
    def is_true_behavior(obj, s):
        if obj.is_immutable_constant():
    def int(obj):
        return SomeInteger()
 
    def float(obj):
        return SomeFloat()
class __extend__(SomeInteger):
 
    def invert(self):
        return SomeInteger(knowntype=self.knowntype)
    invert.can_only_throw = []

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/annotation/builtin.py   plexnet(Download)
 
import sys
from pypy.annotation.model import SomeInteger, SomeObject, SomeChar, SomeBool
from pypy.annotation.model import SomeString, SomeTuple, s_Bool, SomeBuiltin
from pypy.annotation.model import SomeUnicodeCodePoint, SomeAddress
            nonneg = s_stop.nonneg or (s_stop.is_constant() and
                                       s_stop.const >= -1)
        s_item = SomeInteger(nonneg=nonneg)
    return getbookkeeper().newlist(s_item, range_step=step)
 
        args_s = [s_obj]
    nonneg = isinstance(s_obj, SomeInteger) and s_obj.nonneg
    return constpropagate(int, args_s, SomeInteger(nonneg=nonneg))
 
def builtin_float(s_obj):
                nonneg |= s1.nonneg
            if nonneg:
                s = SomeInteger(nonneg=True, knowntype=s.knowntype)
        return s
 
def rarith_intmask(s_obj):
    return SomeInteger()
 
def robjmodel_instantiate(s_clspbc):
    assert isinstance(s_clspbc, SomePBC)

src/s/y/Sypy-HEAD/annotation/builtin.py   Sypy(Download)
 
import sys
from pypy.annotation.model import SomeInteger, SomeObject, SomeChar, SomeBool
from pypy.annotation.model import SomeString, SomeTuple, s_Bool, SomeBuiltin
from pypy.annotation.model import SomeUnicodeCodePoint, SomeAddress
            nonneg = s_stop.nonneg or (s_stop.is_constant() and
                                       s_stop.const >= -1)
        s_item = SomeInteger(nonneg=nonneg)
    return getbookkeeper().newlist(s_item, range_step=step)
 
        args_s = [s_obj]
    nonneg = isinstance(s_obj, SomeInteger) and s_obj.nonneg
    return constpropagate(int, args_s, SomeInteger(nonneg=nonneg))
 
def builtin_float(s_obj):
                nonneg |= s1.nonneg
            if nonneg:
                s = SomeInteger(nonneg=True, knowntype=s.knowntype)
        return s
 
def rarith_intmask(s_obj):
    return SomeInteger()
 
def rarith_longlongmask(s_obj):
    return SomeInteger(knowntype=pypy.rlib.rarithmetic.r_longlong)

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/annotation/bookkeeper.py   plexnet(Download)
 
from pypy.objspace.flow.model import Constant
from pypy.annotation.model import SomeString, SomeChar, SomeFloat, \
     SomePtr, unionof, SomeInstance, SomeDict, SomeBuiltin, SomePBC, \
     SomeInteger, SomeOOInstance, SomeOOObject, TLS, SomeAddress, \
            result = SomeBool()
        elif tp is int:
            result = SomeInteger(nonneg = x>=0)
        elif tp is long and 0 <= x <= (sys.maxint * 2 + 1):
            result = SomeInteger(unsigned = True)

src/s/y/Sypy-HEAD/annotation/bookkeeper.py   Sypy(Download)
 
from pypy.objspace.flow.model import Constant
from pypy.annotation.model import SomeString, SomeChar, SomeFloat, \
     SomePtr, unionof, SomeInstance, SomeDict, SomeBuiltin, SomePBC, \
     SomeInteger, SomeOOInstance, SomeOOObject, TLS, SomeAddress, \
            result = SomeBool()
        elif tp is int:
            result = SomeInteger(nonneg = x>=0)
        elif tp is long:
            if -sys.maxint-1 <= x <= sys.maxint:
                x = int(x)
                result = SomeInteger(nonneg = x>=0)

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/rpython/memory/gctransform/framework.py   plexnet(Download)
        bk = self.translator.annotator.bookkeeper
        r_typeid16 = rffi.platform.numbertype_to_rclass[TYPE_ID]
        s_typeid16 = annmodel.SomeInteger(knowntype=r_typeid16)
 
        # the point of this little dance is to not annotate
        if root_walker.need_root_stack:
            self.incr_stack_ptr = getfn(root_walker.incr_stack,
                                       [annmodel.SomeInteger()],
                                       annmodel.SomeAddress(),
                                       inline = True)
            self.decr_stack_ptr = getfn(root_walker.decr_stack,
                                       [annmodel.SomeInteger()],
            malloc_fixedsize_clear_meth,
            [s_gc, s_typeid16,
             annmodel.SomeInteger(nonneg=True),
             annmodel.SomeBool(), annmodel.SomeBool(),
             annmodel.SomeBool()], s_gcref,
                malloc_fixedsize_meth,
                [s_gc, s_typeid16,
                 annmodel.SomeInteger(nonneg=True),
                 annmodel.SomeBool(), annmodel.SomeBool(),
                 annmodel.SomeBool()], s_gcref,

src/s/y/Sypy-HEAD/rpython/memory/gctransform/framework.py   Sypy(Download)
        bk = self.translator.annotator.bookkeeper
        r_typeid16 = rffi.platform.numbertype_to_rclass[TYPE_ID]
        s_typeid16 = annmodel.SomeInteger(knowntype=r_typeid16)
 
        # the point of this little dance is to not annotate
        data_classdef.generalize_attr(
            'max_type_id',
            annmodel.SomeInteger())
        data_classdef.generalize_attr(
            'typeids_z',
        if root_walker.need_root_stack:
            self.incr_stack_ptr = getfn(root_walker.incr_stack,
                                       [annmodel.SomeInteger()],
                                       annmodel.SomeAddress(),
                                       inline = True)
            self.decr_stack_ptr = getfn(root_walker.decr_stack,
                                       [annmodel.SomeInteger()],
            malloc_fixedsize_clear_meth,
            [s_gc, s_typeid16,
             annmodel.SomeInteger(nonneg=True),
             annmodel.SomeBool(),
             annmodel.SomeBool(),

src/p/l/plexnet-HEAD/third_party/generic/pypy/pypy/translator/stackless/transform.py   plexnet(Download)
        s_argv = translator.annotator.binding(oldgraph.getargs()[0])
        self.slp_entry_point_ptr = mixlevelannotator.constfunc(
            slp_entry_point, [s_argv], annmodel.SomeInteger())
 
        unwinddef = bk.getuniqueclassdef(code.UnwindException)
                code.fetch_retval_void, [], annmodel.s_None),
            lltype.SignedLongLong: mixlevelannotator.constfunc(
                code.fetch_retval_longlong, [], annmodel.SomeInteger(knowntype=rarithmetic.r_longlong)),
            lltype.Signed: mixlevelannotator.constfunc(
                code.fetch_retval_long, [], annmodel.SomeInteger()),
                    code.yield_current_frame_to_caller, [], s_StatePtr),
                'stack_frames_depth':  mixlevelannotator.constfunc(
                    code.stack_frames_depth, [], annmodel.SomeInteger()),
                'stack_switch': mixlevelannotator.constfunc(
                    code.ll_frame_switch, [s_StatePtr], s_StatePtr),
                    code.ll_stack_capture, [], s_StatePtr),
                'get_stack_depth_limit': mixlevelannotator.constfunc(
                    code.ll_get_stack_depth_limit, [], annmodel.SomeInteger()),
                'set_stack_depth_limit': mixlevelannotator.constfunc(
                    code.ll_set_stack_depth_limit, [annmodel.SomeInteger()],

src/s/y/Sypy-HEAD/jit/backend/llgraph/llimpl.py   Sypy(Download)
    s_FloatStorage = annmodel.SomeFloat()
elif longlong.FLOATSTORAGE is lltype.SignedLongLong:
    s_FloatStorage = annmodel.SomeInteger(knowntype=longlong.r_float_storage)
else:
    assert 0
 
setannotation(compile_start, s_CompiledLoop)
setannotation(compile_start_int_var, annmodel.SomeInteger())
setannotation(compile_start_ref_var, annmodel.SomeInteger())
setannotation(compile_start_float_var, annmodel.SomeInteger())
setannotation(compile_add_ref_const, annmodel.s_None)
setannotation(compile_add_float_const, annmodel.s_None)
setannotation(compile_add_int_result, annmodel.SomeInteger())
setannotation(compile_add_ref_result, annmodel.SomeInteger())
setannotation(compile_add_float_result, annmodel.SomeInteger())

  1 | 2 | 3 | 4 | 5 | 6 | 7 | 8  Next