{ "info": { "author": "Mark Sierak", "author_email": "mZarjk_@mailfence.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Developers", "License :: OSI Approved :: GNU Lesser General Public License v3 or later (LGPLv3+)", "Operating System :: OS Independent", "Programming Language :: Python :: 3", "Programming Language :: Python :: Implementation :: CPython", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "cinc provides fixed-width C-like integer types. The speed of these types are\ncomparable to python ints.\n\n=====\nUsage\n=====\n\nSigned types are named \"intN\" and unsigned types are named \"uintN\", where \"N\"\nis the number of bits. Types for 8, 16, 32 and 64 bits are provided.\n\ncinc integers can be constructed from Python ints or cast from another cinc\ntype. If the source integer has more bits than the cinc type then it is\ntruncated:\n\n.. code:: python\n\n >>> x = uint32(0xFFFFFFFF)\n >>> x\n cinc.uint32(4294967295)\n >>> uint16(x)\n cinc.uint16(65535)\n\n==========\nArithmetic\n==========\n\ncinc integers are compatible with python ints. Comparisons and operators cast\nthe integer to their cinc type before performing the comparison or operation.\n\nThe result of the operation has the same type as the left operand:\n\n.. code:: python\n\n >>> x = uint32(2)\n >>> y = int32(2)\n >>> x + y\n cinc.uint32(4)\n >>> y + x\n cinc.int32(4)\n\nThis applies to operations with python ints too:\n\n.. code:: python\n\n >>> x = uint32(2)\n >>> x + 2\n cinc.uint32(4)\n >>> 2 + x\n 4\n\nThere are also methods for bit rotate operations and bit insertion and\nextraction:\n\n.. code:: python\n\n >>> x = uint32(0x000000ff)\n >>> hex(x.rrotate(8))\n '0xff000000'\n >>> y = uint32(0xff000000)\n >>> hex(y.insert(0xff, 8, 8))\n '0xff00ff00'\n >>> hex(y.extract(16, 16))\n '0xff00'\n\n===============\nPython Fallback\n===============\n\nIf no C++ compiler is available during installation, then a Python source module\nbased on ctypes is used instead. The Python version is significantly slower than\nthe compiled C\nextension.\n\n=========\nChangelog\n=========\n\n2.0\n---\n\n* cinc types are now compatible with python ints.\n* A pure Python module was added.", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://pypi.org/project/cinc/", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "cinc", "package_url": "https://pypi.org/project/cinc/", "platform": "", "project_url": "https://pypi.org/project/cinc/", "project_urls": { "Homepage": "https://pypi.org/project/cinc/" }, "release_url": "https://pypi.org/project/cinc/2.0.post1/", "requires_dist": null, "requires_python": "", "summary": "Fast fixed-sized C-like integer types.", "version": "2.0.post1" }, "last_serial": 5606801, "releases": { "1.0": [ { "comment_text": "", "digests": { "md5": "db63b7759e1103c18be0eb7adfa3fc69", "sha256": "5640c805b05867fbb8b43e5ca688223e6a5a280f714afb139e394df6ef7ef7f1" }, "downloads": -1, "filename": "cinc-1.0.tar.gz", "has_sig": false, "md5_digest": "db63b7759e1103c18be0eb7adfa3fc69", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8077, "upload_time": "2014-09-15T14:58:07", "url": "https://files.pythonhosted.org/packages/e9/88/4606e359d33f1565d1f8e79621d9d8542b2056e7ccd65e0b4d5b0e268204/cinc-1.0.tar.gz" } ], "1.0.1": [ { "comment_text": "", "digests": { "md5": "eb2bcc7bd366fdeeb59f2ca2bbaa9927", "sha256": "5cae106460ee0db3cbed8808bed7f355b6c45c0944d357e5e80fc3374a009a71" }, "downloads": -1, "filename": "cinc-1.0.1.tar.gz", "has_sig": false, "md5_digest": "eb2bcc7bd366fdeeb59f2ca2bbaa9927", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8168, "upload_time": "2015-04-09T10:20:47", "url": "https://files.pythonhosted.org/packages/a2/20/8c43558c805edca83701e7a7bbdaf7730d3e66623b30e8a46437257b7529/cinc-1.0.1.tar.gz" } ], "2.0": [ { "comment_text": "", "digests": { "md5": "1f25725668fd8108b8e3c09631b66570", "sha256": "8c2c43f6a05147c40a778547a29fa1ccd52704b947309887b13146ae060332ac" }, "downloads": -1, "filename": "cinc-2.0.tar.gz", "has_sig": false, "md5_digest": "1f25725668fd8108b8e3c09631b66570", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10815, "upload_time": "2019-07-30T09:30:50", "url": "https://files.pythonhosted.org/packages/24/3b/3a523831fe6f4293996a6ded9dff70fa889f4bdefe8670860d7c0d7f14e9/cinc-2.0.tar.gz" } ], "2.0.post1": [ { "comment_text": "", "digests": { "md5": "313b16c132882f0e7ffc1bb705deabc2", "sha256": "e63efe6d7954212bb455c2ba540412eeaf968344614d204fb90217af9fcea895" }, "downloads": -1, "filename": "cinc-2.0.post1.tar.gz", "has_sig": false, "md5_digest": "313b16c132882f0e7ffc1bb705deabc2", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10843, "upload_time": "2019-07-30T09:54:19", "url": "https://files.pythonhosted.org/packages/10/20/123d80d552d08d7b9c2ed4c262f8e2ff101a18acf321f06f85dd9607a7ea/cinc-2.0.post1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "313b16c132882f0e7ffc1bb705deabc2", "sha256": "e63efe6d7954212bb455c2ba540412eeaf968344614d204fb90217af9fcea895" }, "downloads": -1, "filename": "cinc-2.0.post1.tar.gz", "has_sig": false, "md5_digest": "313b16c132882f0e7ffc1bb705deabc2", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 10843, "upload_time": "2019-07-30T09:54:19", "url": "https://files.pythonhosted.org/packages/10/20/123d80d552d08d7b9c2ed4c262f8e2ff101a18acf321f06f85dd9607a7ea/cinc-2.0.post1.tar.gz" } ] }