Matthew Brown
4c3dacbbed
Prevent erroneous __toString conversion in method check
2017-01-27 18:06:11 -07:00
Matthew Brown
6bcc763414
Fix #3 by checking inside __constructor calls for initialisations
2017-01-26 23:23:12 -07:00
Matthew Brown
ff46487353
Be more discerning about unaryminus/plus inferred type
2017-01-25 21:50:34 -07:00
Matthew Brown
c14a19370f
Improve UnaryPlus/Minus still more
2017-01-25 20:23:06 -07:00
Matthew Brown
f03807e7b7
Fix unaryplus/minus type inference
2017-01-25 20:02:19 -07:00
Matthew Brown
ea63fd7ae3
Fix #75 - allow inteeger offsets for object-like arrays
2017-01-25 00:11:24 -07:00
Matthew Brown
0da9c10d36
Don’t complain when adding array and object-like array
2017-01-23 15:40:55 -07:00
Matthew Brown
374dc65de1
Fix #39 by checking for ArrayAcces interface
2017-01-20 00:23:58 -05:00
Matthew Brown
894b25487f
Fix #71 - prevent instantiation of abstract classes
2017-01-20 00:10:10 -05:00
Matt Brown
d0207b6098
Check that class exists before checking for ArrayAccess inheritors
2017-01-19 19:02:00 -05:00
Matt Brown
a67800cac7
Ignore cloning of mixed variables
2017-01-19 15:00:05 -05:00
Matt Brown
7116585e85
Be more robust when ignoring UndefinedClass errors
2017-01-19 11:45:25 -05:00
Matt Brown
a2750a92aa
Evaluate loop part of for after body
2017-01-18 17:13:20 -05:00
Matthew Brown
e78e710eef
Be more resilient in the face of class_exists
checks
2017-01-17 23:34:17 -05:00
Matt Brown
dae7718ae8
Support array_combine types and introduce a MoreSpecificReturnType issue
2017-01-17 11:17:49 -05:00
Matthew Brown
e4769fd04a
Don’t give up when faced with variadic type
2017-01-17 00:07:58 -05:00
Matthew Brown
3cdb1753d5
Update to the more accurate TypeChecker::isContainedBy
2017-01-16 20:00:51 -05:00
Matthew Brown
9220b958eb
Fix phpcs errors
2017-01-16 19:06:39 -05:00
Matthew Brown
b3726c9de5
Use getcwd() for the project’s base, not the config file parent directory
2017-01-16 18:33:04 -05:00
Matthew Brown
e3a9cb98c3
Add extra issue for invalid clone and fix issue reporting;
2017-01-16 12:59:09 -05:00
Matthew Brown
4b283564ca
Allow variadic params to be passed by reference
2017-01-16 12:39:38 -05:00
Matthew Brown
5315fd15ad
Fix namespaced functions in regular use statements
2017-01-16 00:49:12 -05:00
Matthew Brown
ac92de181f
Allow classes that use __invoke to be called
2017-01-16 00:29:18 -05:00
Matthew Brown
f614944b63
Add predefined functions to avoid throwing errors
2017-01-15 20:11:02 -05:00
Matthew Brown
ce89ac4986
Fix #50 - asserting about docblock types no longer causes error
2017-01-15 17:52:01 -05:00
Matthew Brown
9b06b672ba
Fix #54 - register function constants when function is invoked
2017-01-15 16:43:49 -05:00
Matthew Brown
faccc73dc1
Fix #52 by analysing non-main parts of issets
2017-01-15 13:58:20 -05:00
Matthew Brown
8836f05027
Fix #56 - functions in root namespaces should not need slash
2017-01-15 12:34:23 -05:00
Matthew Brown
ad38a26524
Hoist class check above method check
2017-01-15 10:24:38 -05:00
Matthew Brown
03141e41c2
Move string-stored types into named classes
2017-01-15 10:22:05 -05:00
Matt Brown
35c06261b9
Fix #38 - emit issue for non-array on right too
2017-01-13 13:09:52 -05:00
Matt Brown
dc585ff22a
Fix #47 - check closure param types properly
2017-01-13 12:40:01 -05:00
Matthew Brown
c20f31855c
Fix namespaced function calls
2017-01-12 09:42:24 -05:00
Matthew Brown
5f54a9571c
Fix deep project checks
2017-01-12 01:03:48 -05:00
Matthew Brown
56be346191
Add back mutation checks
2017-01-11 21:37:53 -05:00
Matthew Brown
380ae61b3c
Don’t emit another error if we’re already ignoring TypeCoercion
2017-01-09 00:58:18 -05:00
Matthew Brown
bf76843d94
Fix foreach dependency errors
2017-01-09 00:58:05 -05:00
Matthew Brown
f318c52876
Improve function rechecking
2017-01-09 00:31:23 -05:00
Matthew Brown
03c5ea3cef
Store all class keys lowercased
2017-01-09 00:14:39 -05:00
Matthew Brown
5cc97e380d
Fix issue evaluating Foo::class
2017-01-07 17:24:43 -05:00
Matthew Brown
28cd8caca8
Change analyzeMethods to analyze
2017-01-07 15:57:25 -05:00
Matthew Brown
17329015dc
Discriminate between checking, visiting and analyzing in method names
2017-01-07 15:09:47 -05:00
Matthew Brown
694da2cabd
Simplify a lot of APIs
2017-01-07 14:35:07 -05:00
Matthew Brown
6ee69e547f
Do more to separate out processing steps
2017-01-06 01:07:11 -05:00
Matthew Brown
7609ca02c0
Fix #32 by evaluating all class references in files lazily
2017-01-04 23:42:58 -05:00
Matthew Brown
882c8a8d0c
Add better checking of property array assignments
2017-01-02 00:08:35 -05:00
Matthew Brown
d9bf89f72b
Fix multiple possible method signature bug
2017-01-01 20:10:28 -05:00
Matthew Brown
30a39a0ee6
Do not emit issue when callable is called
2017-01-01 19:24:15 -05:00
Matthew Brown
883ca6a5db
Fix #30 by consolidating properties into single storage array
2017-01-01 19:09:17 -05:00
Matthew Brown
8f7072c175
Fix change empty arrays to nulls
2017-01-01 17:39:39 -05:00
Matthew Brown
0b3b3f01f3
Fix support for traits returning self
2016-12-31 11:49:04 -05:00
Matthew Brown
846cc59d5f
Add support for checking closure return types
2016-12-31 10:51:42 -05:00
Matthew Brown
34c238c1a7
Fall through when checking for static/deprecated
2016-12-31 09:25:04 -05:00
Matthew Brown
49f7817a2a
Emit specific issue when calling instance method with self::
2016-12-31 09:20:10 -05:00
Matthew Brown
a524ca8184
Suppress more notices
2016-12-30 20:39:12 -05:00
Matthew Brown
b068bd7858
Fix many bugs
2016-12-30 20:05:32 -05:00
Matthew Brown
4a10bdbc60
Fix suppressed warnings in tests
2016-12-30 19:36:35 -05:00
Matthew Brown
f515327f16
Fix file_name/file_path mixup
2016-12-30 19:06:45 -05:00
Matthew Brown
c65a0bf181
Move function static arrays into FileStorage
2016-12-30 18:08:07 -05:00
Matthew Brown
21816723c7
Make config schema more relaxed about ordering and fix trait bugs
2016-12-30 01:51:29 -05:00
Matthew Brown
3e78405836
# This is a combination of 4 commits.
...
# The first commit's message is:
Make cofig schema more relaxed about ordering
# This is the 2nd commit message:
Add tests for awkward case
# This is the 3rd commit message:
Fix static calls to class methods within traits
# This is the 4th commit message:
Repopulate fewer arrays
2016-12-30 01:50:33 -05:00
Matthew Brown
641ffc09c9
Add NullOperand issue for easy ignoring
2016-12-29 00:32:12 -05:00
Matthew Brown
18e7c65430
Emit more InvalidOperand issues
2016-12-29 00:14:06 -05:00
Matthew Brown
b6455a2566
Improve how we disable clauses
2016-12-28 18:55:16 -05:00
Matthew Brown
63a75108f5
Evaluate more expressions up front
2016-12-28 17:04:03 -05:00
Matthew Brown
992e7ae256
Fix #1 - add in support for !==false-negating assertions in ifs
2016-12-28 16:39:05 -05:00
Matthew Brown
797875ba9a
Fix #10 - allow negated assignments
2016-12-28 16:29:50 -05:00
Matthew Brown
ea30af8a5a
Move assertion checks into separate file
2016-12-28 15:52:44 -05:00
Matthew Brown
4919252260
Fix leaking ref in SwitchChecker
2016-12-28 14:38:16 -05:00
Matthew Brown
6972c45c14
Remove vars from parent clauses when they are reconciled with vars
2016-12-28 14:20:16 -05:00
Matthew Brown
05834a0db3
Fix #13 by revamping how we treat type assertions in if statements and ternary expressions
2016-12-28 13:12:06 -05:00
Matthew Brown
513fcea101
Only assign type when not null
2016-12-25 01:12:26 +00:00
Matthew Brown
1fe0eee8e4
Add generic type coercion checks
2016-12-25 01:08:58 +00:00
Matthew Brown
c51d8f5220
Implement MixedOperand and InvalidOperand issues
2016-12-24 18:29:11 +00:00
Matthew Brown
c55870e26c
Allow generic TypeChecker::isContainedBy checks
2016-12-24 18:28:43 +00:00
Matthew Brown
9746c8972f
Fix MixedAssignment errors
2016-12-17 00:48:31 -05:00
Matt Brown
d012510a41
Fix some mixed assignment issues
2016-12-16 19:22:30 -05:00
Matt Brown
6755c8724a
Add tests for M* issues, fixing bugs along the way
2016-12-16 18:56:23 -05:00
Matthew Brown
dcec735d11
Fix generation of MixedArrayAccess issue
2016-12-15 01:28:36 -05:00
Matt Brown
1d804cde66
Expand scope of property checks
2016-12-14 19:19:25 -05:00
Matt Brown
1b8abc8f17
Change NullReference issue to NullArgument when in method call
2016-12-14 12:54:34 -05:00
Matt Brown
154d023a9d
Add more robust config testing
2016-12-14 12:28:38 -05:00
Matthew Brown
592ee98efc
Fix bugs discovered by adding more tests
2016-12-11 23:40:46 -05:00
Matthew Brown
a84ae58c32
Emit InaccessibleProperty issue where appropriate
2016-12-11 22:18:12 -05:00
Matthew Brown
144625f625
Add numeric check back, with caveats
2016-12-11 20:36:27 -05:00
Matthew Brown
1e8f986d8c
Narrow down error lines for reconcileKeyedTypes
2016-12-11 13:59:36 -05:00
Matthew Brown
562f71b21f
Add TypeDoesNotContainType issue and fix those issues in Psalm code
2016-12-11 13:48:11 -05:00
Matthew Brown
73b1ab1411
Support int offsets in dealing with type inference
2016-12-10 18:24:28 -05:00
Matthew Brown
327e3150a2
Fix erroneous self-check
2016-12-10 15:08:38 -05:00
Matthew Brown
c3df70e634
Allow int offsets to be treated as keys
2016-12-10 15:01:59 -05:00
Matt Brown
eff98bfe00
Ignore nullrefs when using echo
2016-12-09 18:53:26 -05:00
Matt Brown
30159d8f70
Ignore invalid scalar argument issue in echo
2016-12-09 12:53:22 -05:00
Matt Brown
b3106c68bb
Fix #6 - raise error with erroneous __toString
2016-12-09 12:48:02 -05:00
Matt Brown
ce3b24bf5f
Fix #8 - defer always to call map if function not user-defined
2016-12-09 12:07:47 -05:00
Matt Brown
e6ff24b8d2
Fix assignment in elseif
2016-12-09 12:06:14 -05:00
Matt Brown
28621485b0
Add support for parent-defined consts
2016-12-08 17:19:06 -05:00
Matt Brown
260a6d4df5
Make class errors more specific
2016-12-08 17:15:51 -05:00
Matt Brown
c9557d47ce
Fix exponentiation and modulo type inference
2016-12-08 16:37:14 -05:00
Matt Brown
117645ac73
Account for off-by-one issue in PhpParser
2016-12-08 15:57:18 -05:00
Matt Brown
55a060b53a
Add support for closure checks
2016-12-07 14:13:39 -05:00