Git Product home page Git Product logo

phpsignatures's Introduction

PHPSignatures

Overview

This contain signatures with extra details for PHP functions, methods, and properties. These were initially part of Phan, but have been forked in various static analysis tools (Psalm, PHPStan, etc). These differ from other signatures in different ways

  • These signatures also include types where the function/method call would be likely to fail (e.g. runtime errors)

    This differs from repos such as PHPStorm's stubs, which only contain enough information for autocompletion.

  • These contain the nullable type syntax ?T

  • These also contain non-standard generic arrays (such as array<int,T>) and array shapes (such as array{keyName:T})

    Details about the signatures are documented in more detail in FunctionSignatureMap.php.

These signatures were obtained from a wide variety of sources (such as the C source code of PHP, the SVN sources of the php.net documentation, external documentation of third party PHP modules, PHPStorm stubs, bug reports, etc.)

There are minor differences in how these projects use these signatures (such as error handling and type strictness). This repo was created as to make synchronizing fixes to these signatures easier.

  • Changes may be cherry-picked (or merged) for forks of this, possibly with edits.

Layout

FunctionSignatureMap tracks the function and method signatures of the most recent stable PHP release.

  • Delta files can be applied to obtain the function and method signatures of older releases.

DynamicPropertyMap.php contains a set of classes of PHP modules known to have dynamic properties.

PropertyMap.php tracks the union types of properties of known classes of PHP modules.

phpsignatures's People

Contributors

tysonandre avatar muglug avatar daeroni avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.